X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/7bdc18790e34d17edfc02f3e25edcb3425b38a8a..5716a1abb15bfe32b268d543b8f89b5d24118e93:/src/mgl/app.cpp diff --git a/src/mgl/app.cpp b/src/mgl/app.cpp index d8b012870e..d9288130de 100644 --- a/src/mgl/app.cpp +++ b/src/mgl/app.cpp @@ -226,10 +226,12 @@ bool wxApp::SendIdleEvents(wxWindow* win) int wxApp::MainLoop() { + int rt; gs_mainEventLoop = new wxEventLoop; - return gs_mainEventLoop->Run(); + rt = gs_mainEventLoop->Run(); delete gs_mainEventLoop; gs_mainEventLoop = NULL; + return rt; } void wxApp::ExitMainLoop() @@ -239,7 +241,9 @@ void wxApp::ExitMainLoop() bool wxApp::Initialized() { - return (GetTopWindow() != NULL); + // FIXME_MGL -- only for now because we don't have wxFrame/wxDialog yet + return TRUE; + //return (wxTopLevelWindows.GetCount() != 0); } bool wxApp::Pending() @@ -481,8 +485,7 @@ int wxEntry(int argc, char *argv[]) call OnRun() */ wxTheApp->DeletePendingObjects(); - if ( wxTheApp->Initialized() && - wxTopLevelWindows.GetCount() != 0 ) + if ( wxTheApp->Initialized() ) { wxTheApp->OnRun();