[GME-commit] GMESRC/GME/GMEActiveBrowser
ActiveBrowserPropertyPage.cpp, 1.63,
1.64 ActiveBrowserPropertyPage.h, 1.20, 1.21 AggIco.bmp, 1.3,
1.4 AggregateContextMenu.cpp, 1.30,
1.31 AggregateContextMenu.h, 1.10, 1.11 AggregateTreeCtrl.cpp,
1.29, 1.30 AttachLibDlg.cpp, 1.5, 1.6 GMEActiveBrowser.rc,
1.19, 1.20 resource.h, 1.14, 1.15
gme-commit at list.isis.vanderbilt.edu
gme-commit at list.isis.vanderbilt.edu
Wed Sep 26 15:15:55 CDT 2007
- Previous message: [GME-commit] GMESRC/GME/Core CoreAttribute.cpp, 1.20,
1.21 CoreBinFile.cpp, 1.19, 1.20 CoreBinFile.h, 1.12, 1.13
- Next message: [GME-commit]
GMESRC/GME/Mga MgaFCO.h, 1.29, 1.30 MgaFolder.cpp, 1.34,
1.35 MgaFolder.h, 1.9, 1.10 MgaGeneric.cpp, 1.13,
1.14 MgaGeneric.h, 1.10, 1.11 MgaModel.h, 1.6,
1.7 MgaProject.cpp, 1.71, 1.72 MgaProject.h, 1.33, 1.34
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /project/gme-repository/GMESRC/GME/GMEActiveBrowser
In directory escher:/tmp/cvs-serv23801
Modified Files:
ActiveBrowserPropertyPage.cpp ActiveBrowserPropertyPage.h
AggIco.bmp AggregateContextMenu.cpp AggregateContextMenu.h
AggregateTreeCtrl.cpp AttachLibDlg.cpp GMEActiveBrowser.rc
resource.h
Log Message:
ACTIVEBROWSERPROPERTYPAGE.cpp
------------------------------------
1.Made possible attachment of MGX files as Libraries.
2.APPEVENT_LIB_ATTACH_BEGIN/END global event pair sent before/after LibraryAttach
3.freshobject (not saved yet) displayed in Multiuser mode.
AGGREGATETREECTRL.cpp
------------------------------------
1.Detailed error messages when subtype can't be further subtyped
MGAOBJECTProxy.cpp
------------------------------------
Initialization of pointer to 0 never hurts.
CVS User: Zoltan Molnar, ISIS (zolmol)
Index: AggregateContextMenu.cpp
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/GMEActiveBrowser/AggregateContextMenu.cpp,v
retrieving revision 1.30
retrieving revision 1.31
diff -C2 -d -r1.30 -r1.31
*** AggregateContextMenu.cpp 8 Mar 2007 16:55:24 -0000 1.30
--- AggregateContextMenu.cpp 26 Sep 2007 20:15:53 -0000 1.31
***************
*** 98,101 ****
--- 98,104 ----
case ID_POPUP_LIBRARY_DEPENDENCIES: OnLibraryDependencies();break;
case ID_POPUP_LIBRARY_AMBIGUITYCHK: OnLibraryAmbiguityChk();break;
+ case ID_USERS_SOURCECONTROLSTATUS: OnMFSourceControlUpdate();break;
+ case ID_USERS_ACTIVE: OnUsersActive(); break;
+ case ID_USERS_OWNER: OnUsersOwner(); break;
case ID_POPUP_SORT_CONSTRAINTS_CHECKALL: OnCheckAllConstraint();break;
***************
*** 1152,1155 ****
--- 1155,1248 ----
{
m_pParent->LibraryAmbiguityChk();
+ }
+
+ void CAggregateContextMenu::OnMFSourceControlUpdate()
+ {
+ HTREEITEM hItem=m_pParent->m_TreeAggregate.GetSelectedItem();
+ LPUNKNOWN pUnknown=NULL;
+
+ if( hItem == m_pParent->m_TreeAggregate.GetRootItem()) // RootFolder
+ {
+ MSGTRY
+ {
+ m_pParent->ProjectSourceControlUpdate(0);
+ }
+ MSGCATCH("Error while updating source control info for the project!",;)
+ }
+ else if(m_pParent->m_TreeAggregate.m_MgaMap.LookupObjectUnknown(hItem,pUnknown))
+ {
+ CComQIPtr<IMgaFolder> ccpMgaFolder( pUnknown);
+ CComQIPtr<IMgaModel> ccpMgaModel( pUnknown);
+
+ MSGTRY
+ {
+ // Starting transaction
+ CGMEActiveBrowserApp* pApp=(CGMEActiveBrowserApp*)AfxGetApp();
+ CMgaContext* pMgaContext=&pApp->m_CurrentProject.m_MgaContext;
+ pMgaContext->BeginTransaction( TRUE); // it is readonly
+
+ CComBSTR id;
+ if( ccpMgaModel)
+ COMTHROW( ccpMgaModel->get_ID( &id));
+ else if( ccpMgaFolder)
+ COMTHROW( ccpMgaFolder->get_ID( &id));
+
+ // Ending transaction
+ pMgaContext->CommitTransaction();
+
+ // it will open and commit its own transaction
+ m_pParent->ProjectSourceControlUpdate( id);
+ }
+ MSGCATCH("Error while updating source control info!",;)
+
+ //if( ccpMgaModel || ccpMgaFolder)
+ // m_pParent->Refresh();
+ }
+ }
+
+ void CAggregateContextMenu::OnUsersActive()
+ {
+ MSGTRY
+ {
+ // it will open and commit its own transaction
+ m_pParent->SourceControlActiveUsers();
+ }
+ MSGCATCH("Error while updating source control info!",;)
+ }
+
+ void CAggregateContextMenu::OnUsersOwner()
+ {
+ HTREEITEM hItem=m_pParent->m_TreeAggregate.GetSelectedItem();
+ LPUNKNOWN pUnknown=NULL;
+
+ if(m_pParent->m_TreeAggregate.m_MgaMap.LookupObjectUnknown(hItem,pUnknown))
+ {
+ CComQIPtr<IMgaFolder> ccpMgaFolder( pUnknown);
+ CComQIPtr<IMgaModel> ccpMgaModel( pUnknown);
+
+ MSGTRY
+ {
+ // Starting transaction
+ CGMEActiveBrowserApp* pApp=(CGMEActiveBrowserApp*)AfxGetApp();
+ CMgaContext* pMgaContext=&pApp->m_CurrentProject.m_MgaContext;
+ pMgaContext->BeginTransaction( TRUE); // it is readonly
+
+ CComBSTR id;
+ if( ccpMgaModel)
+ COMTHROW( ccpMgaModel->get_ID( &id));
+ else if( ccpMgaFolder)
+ COMTHROW( ccpMgaFolder->get_ID( &id));
+
+ // Ending transaction
+ pMgaContext->CommitTransaction();
+
+ // it will open and commit its own transaction
+ m_pParent->SourceControlObjectOwner( id);
+ }
+ MSGCATCH("Error while updating source control info!",;)
+
+ //if( ccpMgaModel || ccpMgaFolder)
+ // m_pParent->Refresh();
+ }
}
Index: AttachLibDlg.cpp
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/GMEActiveBrowser/AttachLibDlg.cpp,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** AttachLibDlg.cpp 19 Mar 2007 19:32:55 -0000 1.5
--- AttachLibDlg.cpp 26 Sep 2007 20:15:53 -0000 1.6
***************
*** 59,68 ****
{
! static char BASED_CODE szFilter[] = "GME Files (*.mga)|*.mga|All Files (*.*)|*.*||";
CFileDialog dlg(TRUE,"mga",NULL,NULL,szFilter, this);
if(dlg.DoModal()!=IDOK) return;
! m_strConnString="MGA="+dlg.GetPathName();
UpdateData(FALSE);
--- 59,73 ----
{
! static char BASED_CODE szFilter[] = "Binary Project Files (*.mga)|*.mga|Multiuser Project Files (*.mgx)|*.mgx|All Files (*.*)|*.*||";
CFileDialog dlg(TRUE,"mga",NULL,NULL,szFilter, this);
if(dlg.DoModal()!=IDOK) return;
! bool is_mga = dlg.GetFileExt().CompareNoCase( "mga") == 0;
! if( is_mga)
! m_strConnString = "MGA=" + dlg.GetPathName();
! else
! m_strConnString = "MGX=\"" + dlg.GetPathName().Left( dlg.GetPathName().ReverseFind( '\\')) + "\"";
!
UpdateData(FALSE);
Index: ActiveBrowserPropertyPage.cpp
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/GMEActiveBrowser/ActiveBrowserPropertyPage.cpp,v
retrieving revision 1.63
retrieving revision 1.64
diff -C2 -d -r1.63 -r1.64
*** ActiveBrowserPropertyPage.cpp 16 Jun 2007 21:46:01 -0000 1.63
--- ActiveBrowserPropertyPage.cpp 26 Sep 2007 20:15:53 -0000 1.64
***************
*** 213,217 ****
m_TreeAggregate.GetItemImage(pNMTreeView->itemNew.hItem,nImage,nSelectedImage);
! ASSERT(nImage+ICON_NUMBER<6*ICON_NUMBER);
m_TreeAggregate.SetItemImage(pNMTreeView->itemNew.hItem,nImage+ICON_NUMBER,nSelectedImage+ICON_NUMBER);
--- 213,217 ----
m_TreeAggregate.GetItemImage(pNMTreeView->itemNew.hItem,nImage,nSelectedImage);
! ASSERT(nImage+ICON_NUMBER<8*ICON_NUMBER);//WAS 6*ICON_NUMBER, but we have added new images for freshly created objects
m_TreeAggregate.SetItemImage(pNMTreeView->itemNew.hItem,nImage+ICON_NUMBER,nSelectedImage+ICON_NUMBER);
***************
*** 267,323 ****
int CAggregatePropertyPage::GetSourceControlStateOffset(IMgaObject * obj, int * latent)
{
! int ret_val = 0;
try
! {
! CComQIPtr<IMgaFCO> fco(obj);
! if( fco==NULL )
! return ret_val;
! long regCount;
! CComPtr<IMgaRegNodes> regNodes;
! COMTHROW(fco->get_Registry( 1, ®Nodes ));
! COMTHROW(regNodes->get_Count(®Count));
! for( int i=1; i<=regCount; ++i )
! {
! CComPtr<IMgaRegNode> reg;
! COMTHROW(regNodes->get_Item(i,®));
- CComBSTR regnodeName;
- COMTHROW(reg->get_Name( ®nodeName ));
! if( regnodeName == "SourceControlInfo" )
! {
! CComBSTR regnodeValue;
! COMTHROW(reg->get_Value(®nodeValue));
! if( regnodeValue == "GME_SourceControl_State_local" )
! ret_val = 4*ICON_NUMBER;
! else if( regnodeValue == "GME_SourceControl_State_other" )
! ret_val = 2*ICON_NUMBER;
! else
! ret_val = 0;
! }
! if( regnodeName == "SourceControlStat")
! {
! CComBSTR regnodeValue;
! COMTHROW(reg->get_Value(®nodeValue));
! if( regnodeValue == "GME_SourceControl_File_ModByOthers" )
! *latent = 1;
! else if( regnodeValue == "GME_SourceControl_File_UpToDate" )
! *latent = 0;
! }
! }
! }
! catch(...)
! {
! }
! if( *latent)
! {
! ret_val = ret_val + 10-1; // library icon, possibly decorated with the red or green tick
*latent = 0;
- }
- return ret_val;
- }
CString CAggregatePropertyPage::GetDisplayedName(IMgaObject *pIMgaObject)
--- 267,320 ----
int CAggregatePropertyPage::GetSourceControlStateOffset(IMgaObject * obj, int * latent)
{
! int ret_val = 0; bool saved = true;
! long st = 0; // state of the object
!
try
! {
! CComQIPtr<IMgaModel> mod( obj);
! if( mod != NULL ) // if model
! {
! COMTHROW( mod->GetSourceControlInfo( &st));
! }
! else
! {
! CComQIPtr<IMgaFolder> fol( obj);
! if( fol != NULL) // if folder
! COMTHROW( fol->GetSourceControlInfo( &st));
! else
! return ret_val;
! }
! }
! catch(...)
! {
! return ret_val;
! }
! const int LOC = 0x1; // "GME_SourceControl_State_local"
! const int OTH = 0x2; // "GME_SourceControl_State_other"
! if( st & LOC) // "GME_SourceControl_State_local"
! ret_val = 4*ICON_NUMBER;
! else if( st & OTH) // "GME_SourceControl_State_other"
! ret_val = 2*ICON_NUMBER;
! else
! ret_val = 0;
! //const int UTD = 0x000; // "GME_SourceControl_File_UpToDate"
! const int MBO = 0x100; // "GME_SourceControl_File_ModByOthers"
! const int NYS = 0x200; // "GME_SourceControl_File_NotYetSaved"
!
! if( st & MBO) // "GME_SourceControl_File_ModByOthers"
! *latent = 1;
! else if( st & NYS) // "GME_SourceControl_File_NotYetSaved"
! saved = false, *latent = 0;//ret_val = 6 * ICON_NUMBER;
! else// if( st & UTD) // "GME_SourceControl_File_UpToDate"
*latent = 0;
+ if( !saved)
+ ret_val = 6*ICON_NUMBER, *latent = 0;
+ return ret_val;
+ }
CString CAggregatePropertyPage::GetDisplayedName(IMgaObject *pIMgaObject)
***************
*** 1544,1549 ****
if(dlg.DoModal() == IDOK && !dlg.m_strConnString.IsEmpty())
{
! if( dlg.m_strConnString.Left(4) != "MGA=") dlg.m_strConnString.Insert(0, "MGA=");
! if( dlg.m_strConnString.Find( ".") == -1) dlg.m_strConnString += ".mga";
MSGTRY {
--- 1541,1559 ----
if(dlg.DoModal() == IDOK && !dlg.m_strConnString.IsEmpty())
{
! // be flexible in MGA case ( if "MGX" is not present )
! if( dlg.m_strConnString.Left(4) == "MGX=")
! {
! // add quotes to the folderpath if not there
! if( dlg.m_strConnString.Mid(4,1) != "\"" && dlg.m_strConnString.Right(1) != "\"")
! dlg.m_strConnString = "MGX=\"" + dlg.m_strConnString.Mid( 4) + "\"";
! }
! else // MGA is presumed in this case
! {
! // add extension
! if( dlg.m_strConnString.Find( ".") == -1) dlg.m_strConnString += ".mga";
!
! // add the 'MGA=' prefix
! if( dlg.m_strConnString.Left(4) != "MGA=") dlg.m_strConnString.Insert(0, "MGA=");
! }
MSGTRY {
***************
*** 1565,1568 ****
--- 1575,1579 ----
// toggle off Constraint Manager
if( pMgaContext && pMgaContext->m_ccpConstMgr) COMTHROW( pMgaContext->m_ccpConstMgr->Enable( false));
+ if( pMgaContext && pMgaContext->m_ccpProject) COMTHROW( pMgaContext->m_ccpProject->Notify( APPEVENT_LIB_ATTACH_BEGIN));
pMgaContext->BeginTransaction(FALSE);
***************
*** 1573,1576 ****
--- 1584,1588 ----
// toggle back Constraint Manager (done only after commit, so that it will not catch the events happened in the transaction)
if( pMgaContext && pMgaContext->m_ccpConstMgr) COMTHROW( pMgaContext->m_ccpConstMgr->Enable( true));
+ if( pMgaContext && pMgaContext->m_ccpProject) COMTHROW( pMgaContext->m_ccpProject->Notify( APPEVENT_LIB_ATTACH_END));
CComBSTR msg( L"Library attached: ");
***************
*** 3963,3966 ****
--- 3975,4033 ----
//Refresh();
}
+ }
+
+ void CAggregatePropertyPage::ProjectSourceControlUpdate( CComBSTR id)
+ {
+ CGMEActiveBrowserApp* pApp=(CGMEActiveBrowserApp*)AfxGetApp();
+ CMgaContext* pMgaContext=&pApp->m_CurrentProject.m_MgaContext;
+
+
+ MSGTRY
+ {
+ CGMEActiveBrowserApp* pApp=(CGMEActiveBrowserApp*)AfxGetApp();
+ CMgaContext* pMgaContext=&pApp->m_CurrentProject.m_MgaContext;
+
+ // no transaction needed
+ COMTHROW( pMgaContext->m_ccpProject->UpdateSourceControlInfo( id));
+ }
+ MSGCATCH("Error while updating source control info!",;)
+
+ Refresh();
+ }
+
+ void CAggregatePropertyPage::SourceControlObjectOwner( CComBSTR p_id)
+ {
+ CGMEActiveBrowserApp* pApp=(CGMEActiveBrowserApp*)AfxGetApp();
+ CMgaContext* pMgaContext=&pApp->m_CurrentProject.m_MgaContext;
+
+ MSGTRY
+ {
+ CGMEActiveBrowserApp* pApp=(CGMEActiveBrowserApp*)AfxGetApp();
+ CMgaContext* pMgaContext=&pApp->m_CurrentProject.m_MgaContext;
+
+ // no transaction needed
+ COMTHROW( pMgaContext->m_ccpProject->SourceControlObjectOwner( p_id));
+ }
+ MSGCATCH("Error while fetching source control info!",;)
+
+ Refresh();
+ }
+
+ void CAggregatePropertyPage::SourceControlActiveUsers()
+ {
+ CGMEActiveBrowserApp* pApp=(CGMEActiveBrowserApp*)AfxGetApp();
+ CMgaContext* pMgaContext=&pApp->m_CurrentProject.m_MgaContext;
+
+ MSGTRY
+ {
+ CGMEActiveBrowserApp* pApp=(CGMEActiveBrowserApp*)AfxGetApp();
+ CMgaContext* pMgaContext=&pApp->m_CurrentProject.m_MgaContext;
+
+ // no transaction needed
+ COMTHROW( pMgaContext->m_ccpProject->SourceControlActiveUsers());
+ }
+ MSGCATCH("Error while fetching source control info!",;)
+
+ Refresh();
}
Index: AggregateContextMenu.h
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/GMEActiveBrowser/AggregateContextMenu.h,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -d -r1.10 -r1.11
*** AggregateContextMenu.h 7 Mar 2007 21:29:05 -0000 1.10
--- AggregateContextMenu.h 26 Sep 2007 20:15:53 -0000 1.11
***************
*** 26,29 ****
--- 26,32 ----
void OnLibraryDependencies();
void OnLibraryAmbiguityChk();
+ void OnMFSourceControlUpdate();
+ void OnUsersActive();
+ void OnUsersOwner();
UINT m_nSelectionCount;
Index: ActiveBrowserPropertyPage.h
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/GMEActiveBrowser/ActiveBrowserPropertyPage.h,v
retrieving revision 1.20
retrieving revision 1.21
diff -C2 -d -r1.20 -r1.21
*** ActiveBrowserPropertyPage.h 16 Jun 2007 21:46:01 -0000 1.20
--- ActiveBrowserPropertyPage.h 26 Sep 2007 20:15:53 -0000 1.21
***************
*** 31,34 ****
--- 31,37 ----
void LibraryDependencies();
void LibraryAmbiguityChk();
+ void ProjectSourceControlUpdate( CComBSTR p_id);
+ void SourceControlObjectOwner( CComBSTR p_id);
+ void SourceControlActiveUsers();
bool askUserAndDeleteLibrary( CComPtr<IMgaFolder> p_ccpFolder);
Index: AggIco.bmp
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/GMEActiveBrowser/AggIco.bmp,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
Binary files /tmp/cvsHWYxWV and /tmp/cvsLF3mNF differ
Index: resource.h
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/GMEActiveBrowser/resource.h,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -d -r1.14 -r1.15
*** resource.h 19 Mar 2007 19:32:55 -0000 1.14
--- resource.h 26 Sep 2007 20:15:53 -0000 1.15
***************
*** 82,85 ****
--- 82,89 ----
#define ID_POPUP_LIBRARY_AMBIGUITYCHK 32806
#define ID_POPUP_READWRITE 32807
+ #define ID__USERS 32808
+ #define ID_USERS_SOURCECONTROLSTATUS 32809
+ #define ID_USERS_OWNER 32810
+ #define ID_USERS_ACTIVE 32811
// Next default values for new objects
***************
*** 88,92 ****
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 220
! #define _APS_NEXT_COMMAND_VALUE 32808
#define _APS_NEXT_CONTROL_VALUE 221
#define _APS_NEXT_SYMED_VALUE 104
--- 92,96 ----
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 220
! #define _APS_NEXT_COMMAND_VALUE 32812
#define _APS_NEXT_CONTROL_VALUE 221
#define _APS_NEXT_SYMED_VALUE 104
Index: AggregateTreeCtrl.cpp
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/GMEActiveBrowser/AggregateTreeCtrl.cpp,v
retrieving revision 1.29
retrieving revision 1.30
diff -C2 -d -r1.29 -r1.30
*** AggregateTreeCtrl.cpp 16 Jun 2007 21:46:01 -0000 1.29
--- AggregateTreeCtrl.cpp 26 Sep 2007 20:15:53 -0000 1.30
***************
*** 69,73 ****
CComQIPtr<IMgaObject> ccpMgaObject(pUnknown);
tvInsert.item.cChildren=pParent->reqHasDisplayedChild(ccpMgaObject);
! sourceControlImageOffset = pParent->GetSourceControlStateOffset(ccpMgaObject, &sourceControlLatentState);
}
else
--- 69,73 ----
CComQIPtr<IMgaObject> ccpMgaObject(pUnknown);
tvInsert.item.cChildren=pParent->reqHasDisplayedChild(ccpMgaObject);
! //sourceControlImageOffset = pParent->GetSourceControlStateOffset(ccpMgaObject, &sourceControlLatentState);
}
else
***************
*** 75,79 ****
tvInsert.item.cChildren=0;
}
!
}
else
--- 75,79 ----
tvInsert.item.cChildren=0;
}
! sourceControlImageOffset = pParent->GetSourceControlStateOffset(CComQIPtr<IMgaObject>( pUnknown), &sourceControlLatentState);
}
else
***************
*** 85,90 ****
{
! tvInsert.item.iImage=0;
! tvInsert.item.iSelectedImage=0;
}
else
--- 85,90 ----
{
! tvInsert.item.iImage=0+sourceControlImageOffset;
! tvInsert.item.iSelectedImage=0+sourceControlImageOffset;
}
else
***************
*** 157,161 ****
CComQIPtr<IMgaObject> ccpMgaObject(pUnknown);
tvInsert.item.cChildren=pParent->reqHasDisplayedChild(ccpMgaObject);
! sourceControlImageOffset = pParent->GetSourceControlStateOffset(ccpMgaObject, &sourceControlLatentState);
}
else
--- 157,161 ----
CComQIPtr<IMgaObject> ccpMgaObject(pUnknown);
tvInsert.item.cChildren=pParent->reqHasDisplayedChild(ccpMgaObject);
! //sourceControlImageOffset = pParent->GetSourceControlStateOffset(ccpMgaObject, &sourceControlLatentState);
}
else
***************
*** 163,167 ****
tvInsert.item.cChildren=0;
}
!
}
else
--- 163,167 ----
tvInsert.item.cChildren=0;
}
! sourceControlImageOffset = pParent->GetSourceControlStateOffset(CComQIPtr<IMgaObject>( pUnknown), &sourceControlLatentState);
}
else
***************
*** 173,178 ****
{
! tvInsert.item.iImage=0;
! tvInsert.item.iSelectedImage=0;
}
else
--- 173,178 ----
{
! tvInsert.item.iImage=0+sourceControlImageOffset;
! tvInsert.item.iSelectedImage=0+sourceControlImageOffset;
}
else
***************
*** 187,192 ****
if(IsLibrary(pUnknown, &has_dep))
{
! tvInsert.item.iImage=10;
! tvInsert.item.iSelectedImage=10;
if( has_dep)
{
--- 187,192 ----
if(IsLibrary(pUnknown, &has_dep))
{
! tvInsert.item.iImage=10 + sourceControlImageOffset;
! tvInsert.item.iSelectedImage=10 + sourceControlImageOffset;
if( has_dep)
{
***************
*** 911,915 ****
{
CComPtr<IMgaFCO> ccpNewFco;
! COMTHROW( ccpTargetFolder->DeriveRootObject(MGACOLL_ITER,VARIANT_TRUE,&ccpNewFco));
}
MGACOLL_ITERATE_END;
--- 911,929 ----
{
CComPtr<IMgaFCO> ccpNewFco;
! HRESULT hr;
! if( ( hr = ccpTargetFolder->DeriveRootObject(MGACOLL_ITER,VARIANT_TRUE,&ccpNewFco)) != S_OK) {
! if( hr == E_MGA_NOT_DERIVABLE) // typical failure code when subtyping/instantiating
! {
! CComBSTR msg( L"Object '"), nm;
! COMTHROW( MGACOLL_ITER->get_Name( &nm));
! msg.Append( nm);
! msg.Append( "' could not be derived. Some of its ancestors or descendants may be already derived! [Error code E_MGA_NOT_DERIVABLE]");
! Utils::put2Console( Utils::get_GME( pMgaContext->m_ccpProject), msg, MSG_ERROR);
! pMgaContext->AbortTransaction();//COMTHROW( hr);
! return FALSE;//break; // although it was inside a MGACOLL_ITERATE, we aborted the trans
! }
! COMTHROW( hr); // otherwise
! break;
! }
}
MGACOLL_ITERATE_END;
***************
*** 921,925 ****
{
CComPtr<IMgaFCO> ccpNewFco;
! COMTHROW( ccpTargetFolder->DeriveRootObject(MGACOLL_ITER,VARIANT_FALSE,&ccpNewFco));
}
MGACOLL_ITERATE_END;
--- 935,954 ----
{
CComPtr<IMgaFCO> ccpNewFco;
! HRESULT hr;
! if( ( hr = ccpTargetFolder->DeriveRootObject(MGACOLL_ITER,VARIANT_FALSE,&ccpNewFco)) != S_OK) {
! //MGATREECTRL_LOGEVENT(" "+fcoName+" cannot be derived.\r\n");
! if( hr == E_MGA_NOT_DERIVABLE) // typical failure code when subtyping/instantiating
! {
! CComBSTR msg( L"Object '"), nm;
! COMTHROW( MGACOLL_ITER->get_Name( &nm));
! msg.Append( nm);
! msg.Append( "' could not be derived. Some of its ancestors or descendants may be already derived! [Error code E_MGA_NOT_DERIVABLE]");
! Utils::put2Console( Utils::get_GME( pMgaContext->m_ccpProject), msg, MSG_ERROR);
! pMgaContext->AbortTransaction();//COMTHROW( hr);
! return FALSE;//break; // although it was inside a MGACOLL_ITERATE, we aborted the trans
! }
! COMTHROW( hr); // otherwise
! break;
! }
}
MGACOLL_ITERATE_END;
***************
*** 1096,1099 ****
--- 1125,1129 ----
{
HRESULT hr = S_OK;
+ bool excep_handled = false;
MGACOLL_ITERATE(IMgaFCO,ccpDroppedFCOs) {
***************
*** 1126,1130 ****
if((hr = ccpTargetModel->DeriveChildObject(ccpFCO,ccpNewMetaRole, inst ,&ccpNewFCO)) != S_OK) {
MGATREECTRL_LOGEVENT(" "+fcoName+" cannot be derived.\r\n");
! COMTHROW( hr);
break;
}
--- 1156,1171 ----
if((hr = ccpTargetModel->DeriveChildObject(ccpFCO,ccpNewMetaRole, inst ,&ccpNewFCO)) != S_OK) {
MGATREECTRL_LOGEVENT(" "+fcoName+" cannot be derived.\r\n");
! if( hr == E_MGA_NOT_DERIVABLE) // typical failure code when subtyping/instantiating
! {
! CComBSTR msg( L"Object '"), nm;
! COMTHROW( ccpFCO->get_Name( &nm));
! msg.Append( nm);
! msg.Append( "' could not be derived. Some of its ancestors or descendants may be already derived! [Error code E_MGA_NOT_DERIVABLE]");
! Utils::put2Console( Utils::get_GME( pMgaContext->m_ccpProject), msg, MSG_ERROR);
!
! pMgaContext->AbortTransaction();//COMTHROW( hr);
! return FALSE;//break; // although it was inside a MGACOLL_ITERATE, we aborted the trans
! }
! COMTHROW( hr); // otherwise
break;
}
***************
*** 1133,1137 ****
}
MGACOLL_ITERATE_END;
-
bRetVal=TRUE;
}break;
--- 1174,1177 ----
Index: GMEActiveBrowser.rc
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/GMEActiveBrowser/GMEActiveBrowser.rc,v
retrieving revision 1.19
retrieving revision 1.20
diff -C2 -d -r1.19 -r1.20
*** GMEActiveBrowser.rc 19 Mar 2007 19:32:55 -0000 1.19
--- GMEActiveBrowser.rc 26 Sep 2007 20:15:53 -0000 1.20
***************
*** 394,397 ****
--- 394,404 ----
END
MENUITEM "&View in Parent", ID_POPUP_SHOWINPARENT
+ POPUP "Mu<i User"
+ BEGIN
+ MENUITEM "&Refresh Status", ID_USERS_SOURCECONTROLSTATUS
+
+ MENUITEM "Show &Owner...", ID_USERS_OWNER
+ MENUITEM "&Active Users...", ID_USERS_ACTIVE
+ END
MENUITEM SEPARATOR
MENUITEM "&Help", ID_POPUP_HELP
- Previous message: [GME-commit] GMESRC/GME/Core CoreAttribute.cpp, 1.20,
1.21 CoreBinFile.cpp, 1.19, 1.20 CoreBinFile.h, 1.12, 1.13
- Next message: [GME-commit]
GMESRC/GME/Mga MgaFCO.h, 1.29, 1.30 MgaFolder.cpp, 1.34,
1.35 MgaFolder.h, 1.9, 1.10 MgaGeneric.cpp, 1.13,
1.14 MgaGeneric.h, 1.10, 1.11 MgaModel.h, 1.6,
1.7 MgaProject.cpp, 1.71, 1.72 MgaProject.h, 1.33, 1.34
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the GME-commit
mailing list