X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/955a919785b76a1826e6b8d55f696a0dfb62a318..4224f059750329cc68964eeb7b2633206e245e0d:/src/mgl/app.cpp diff --git a/src/mgl/app.cpp b/src/mgl/app.cpp index d7126b0fcc..d444527ccf 100644 --- a/src/mgl/app.cpp +++ b/src/mgl/app.cpp @@ -7,7 +7,7 @@ // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// -#ifdef __GNUG__ +#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) #pragma implementation "app.h" #endif @@ -147,7 +147,7 @@ static wxRootWindow *gs_rootWindow = NULL; // MGL initialization //----------------------------------------------------------------------------- -static bool wxCreateMGL_WM(const wxDisplayModeInfo& displayMode) +static bool wxCreateMGL_WM(const wxVideoMode& displayMode) { int mode; int refresh = MGL_DEFAULT_REFRESH; @@ -208,7 +208,7 @@ BEGIN_EVENT_TABLE(wxApp, wxEvtHandler) END_EVENT_TABLE() -wxApp::wxApp() : m_mainLoop(NULL) +wxApp::wxApp() { } @@ -216,7 +216,7 @@ wxApp::~wxApp() { } -wxDisplayModeInfo wxGetDefaultDisplayMode() +wxVideoMode wxGetDefaultDisplayMode() { wxString mode; unsigned w, h, bpp; @@ -227,10 +227,10 @@ wxDisplayModeInfo wxGetDefaultDisplayMode() w = 640, h = 480, bpp = 16; } - return wxDisplayModeInfo(w, h, bpp); + return wxVideoMode(w, h, bpp); } -bool wxApp::SetDisplayMode(const wxDisplayModeInfo& mode) +bool wxApp::SetDisplayMode(const wxVideoMode& mode) { if ( !mode.IsOk() ) { @@ -272,39 +272,6 @@ bool wxApp::OnInitGui() return TRUE; } -int wxApp::MainLoop() -{ - int rt; - m_mainLoop = new wxEventLoop; - - rt = m_mainLoop->Run(); - - delete m_mainLoop; - m_mainLoop = NULL; - return rt; -} - -void wxApp::ExitMainLoop() -{ - if ( m_mainLoop ) - m_mainLoop->Exit(0); -} - -bool wxApp::Initialized() -{ - return (wxTopLevelWindows.GetCount() != 0); -} - -bool wxApp::Pending() -{ - return wxEventLoop::GetActive()->Pending(); -} - -void wxApp::Dispatch() -{ - wxEventLoop::GetActive()->Dispatch(); -} - bool wxApp::Initialize(int& argc, wxChar **argv) { #ifdef __DJGPP__