[GME-commit] GMESRC/GME/Gme GMEApp.cpp,1.127,1.128
gme-commit at list.isis.vanderbilt.edu
gme-commit at list.isis.vanderbilt.edu
Fri Apr 15 20:39:53 CDT 2005
Update of /project/gme-repository/GMESRC/GME/Gme
In directory escher:/tmp/cvs-serv22430
Modified Files:
GMEApp.cpp
Log Message:
CGMEOLEApp object creation done in InitInstance.
CVS User: Zoltan Molnar, ISIS (zolmol)
Index: GMEApp.cpp
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/Gme/GMEApp.cpp,v
retrieving revision 1.127
retrieving revision 1.128
diff -C2 -d -r1.127 -r1.128
*** GMEApp.cpp 26 Jan 2005 17:28:27 -0000 1.127
--- GMEApp.cpp 15 Apr 2005 19:39:50 -0000 1.128
***************
*** 297,300 ****
--- 297,307 ----
MSGCATCH("Error while trying to get logfile settings",;);
+ if( (CMainFrame*)m_pMainWnd)
+ {
+ CGMEOLEApp *t_pGmeOleApp = new CGMEOLEApp();
+ ((CMainFrame*)m_pMainWnd)->setGmeOleApp( t_pGmeOleApp );
+ }
+ else ASSERT(0);
+
// Check to see if launched as OLE server
if (cmdInfo.m_bRunEmbedded || cmdInfo.m_bRunAutomated)
***************
*** 837,846 ****
// Register OLE Server / MGA Client
! CGMEOLEApp *oleApp = new CGMEOLEApp();
CComBSTR clientName(OLESTR("GME.Application"));
! COMTHROW(mgaProject->RegisterClient(clientName, oleApp->GetIDispatch(FALSE), &mgaClient));
! IDispatch *disp = oleApp->GetIDispatch(FALSE);
! ((CMainFrame*)m_pMainWnd)->m_console.SetGMEApp(disp); // ????
! COMTHROW(oleApp->GetIDispatch(FALSE)->Release()); // Do not hold a reference, hopefully the returned client holds it
// notify browser
--- 844,852 ----
// Register OLE Server / MGA Client
! CGMEOLEApp *oleApp = ((CMainFrame*)m_pMainWnd)->mGmeOleApp;
CComBSTR clientName(OLESTR("GME.Application"));
! COMTHROW(mgaProject->RegisterClient(clientName, oleApp->GetIDispatch(FALSE), &mgaClient)); // mgaClient increments the refcount of oleApp->idispatch by 1
!
! ((CMainFrame*)m_pMainWnd)->setMgaProj();
// notify browser
***************
*** 1452,1456 ****
{
CGMEEventLogger::LogGMEEvent("CGMEApp::OnFileCloseproject\r\n");
! ((CMainFrame*)m_pMainWnd)->m_console.SetGMEApp(NULL); // ????
SafeCloseProject();
}
--- 1458,1462 ----
{
CGMEEventLogger::LogGMEEvent("CGMEApp::OnFileCloseproject\r\n");
! ((CMainFrame*)m_pMainWnd)->clearMgaProj();
SafeCloseProject();
}
***************
*** 1481,1485 ****
{
CGMEEventLogger::LogGMEEvent("CGMEApp::OnFileAbortProject\r\n");
! ((CMainFrame*)m_pMainWnd)->m_console.SetGMEApp(NULL); // ????
if(!mgaProject) return;
long l;
--- 1487,1492 ----
{
CGMEEventLogger::LogGMEEvent("CGMEApp::OnFileAbortProject\r\n");
! ((CMainFrame*)m_pMainWnd)->clearMgaProj();
!
if(!mgaProject) return;
long l;
More information about the GME-commit
mailing list