X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/ef344ff86223f1f0961f025c0b249c898529c095..4eb1fe9da6dbf2a82876547b6f69836e086f22e7:/src/mgl/evtloop.cpp diff --git a/src/mgl/evtloop.cpp b/src/mgl/evtloop.cpp index effad7cb10..d19bd8639c 100644 --- a/src/mgl/evtloop.cpp +++ b/src/mgl/evtloop.cpp @@ -74,7 +74,6 @@ private: void wxEventLoopImpl::Dispatch() { event_t evt; - ibool rc; MGL_wmUpdateDC(g_winMng); @@ -153,6 +152,10 @@ void wxEventLoop::Exit(int rc) m_impl->SetExitCode(rc); m_impl->SetKeepLooping(FALSE); + + // Send a dummy event so that the app won't block in EVT_halt if there + // are no user-generated events in the queue: + EVT_post(0, EVT_USEREVT, 0, 0); } // ----------------------------------------------------------------------------