// global data
//-----------------------------------------------------------------------------
-wxApp *wxTheApp = (wxApp *) NULL;
-wxAppInitializerFunction wxAppBase::m_appInitFn = (wxAppInitializerFunction) NULL;
-
bool g_mainThreadLocked = FALSE;
gint g_pendingTag = 0;
void wxapp_install_idle_handler();
-//-----------------------------------------------------------------------------
-// wxExit
-//-----------------------------------------------------------------------------
-
-void wxExit()
-{
- gtk_main_quit();
-}
-
//-----------------------------------------------------------------------------
// wxYield
//-----------------------------------------------------------------------------
// wxWakeUpIdle
//-----------------------------------------------------------------------------
-static bool gs_WakeUpIdle = false;
-
-void wxWakeUpIdle()
+void wxApp::WakeUpIdle()
{
#if wxUSE_THREADS
if (!wxThread::IsMain())
wxMutexGuiEnter();
#endif
- if (g_isIdle) {
- gs_WakeUpIdle = true;
+ if (g_isIdle)
wxapp_install_idle_handler();
- gs_WakeUpIdle = false;
- }
#if wxUSE_THREADS
if (!wxThread::IsMain())
return 0;
}
+void wxApp::Exit()
+{
+ // VZ: no idea why is it different from ExitMainLoop() but this is what
+ // wxExit() used to do
+ gtk_main_quit();
+}
+
void wxApp::ExitMainLoop()
{
if (gtk_main_level() > 0)