X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/57bfe3be851afc62b22e7bacdc67f011f86e7e31..5a410e4453e28ee77ee3ad7a407ca71692f9f30f:/src/motif/app.cpp?ds=inline diff --git a/src/motif/app.cpp b/src/motif/app.cpp index 15e251c45c..a723826ec3 100644 --- a/src/motif/app.cpp +++ b/src/motif/app.cpp @@ -9,7 +9,7 @@ // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// -#ifdef __GNUG__ +#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) #pragma implementation "app.h" #endif @@ -120,7 +120,7 @@ wxApp::wxApp() argc = 0; argv = NULL; - m_eventLoop = new wxEventLoop; + m_mainLoop = new wxEventLoop; m_mainColormap = (WXColormap) NULL; m_appContext = (WXAppContext) NULL; m_initialDisplay = (WXDisplay*) 0; @@ -129,7 +129,7 @@ wxApp::wxApp() wxApp::~wxApp() { - delete m_eventLoop; + delete m_mainLoop; for( wxPerDisplayDataMap::iterator it = m_perDisplayData->begin(), end = m_perDisplayData->end(); @@ -144,14 +144,6 @@ wxApp::~wxApp() wxApp::SetInstance(NULL); } -bool wxApp::Initialized() -{ - if (GetTopWindow()) - return TRUE; - else - return FALSE; -} - int wxApp::MainLoop() { /* @@ -165,36 +157,11 @@ int wxApp::MainLoop() XDefaultRootWindow(XtDisplay((Widget) wxTheApp->GetTopLevelWidget())), PropertyChangeMask); - m_eventLoop->Run(); + m_mainLoop->Run(); return 0; } -void wxApp::ExitMainLoop() -{ - if( m_eventLoop->IsRunning() ) - m_eventLoop->Exit(); -} - -// Is a message/event pending? -bool wxApp::Pending() -{ - return m_eventLoop->Pending(); -#if 0 - XFlush(XtDisplay( (Widget) wxTheApp->GetTopLevelWidget() )); - - // Fix by Doug from STI, to prevent a stall if non-X event - // is found. - return ((XtAppPending( (XtAppContext) GetAppContext() ) & XtIMXEvent) != 0) ; -#endif -} - -// Dispatch a message. -void wxApp::Dispatch() -{ - m_eventLoop->Dispatch(); -} - // This should be redefined in a derived class for // handling property change events for XAtom IPC. void wxApp::HandlePropertyChange(WXEvent *event)