#if wxUSE_THREADS
delete wxPendingEvents;
delete wxPendingEventsLocker;
+ // If we don't do the following, we get an apparent memory leak.
+ ((wxEvtHandler&) wxDefaultValidator).ClearEventLocker();
#endif
wxClassInfo::CleanUpClasses();
DoMessage();
-
- // If they are pending events, we must process them.
-#if wxUSE_THREADS
- ProcessPendingEvents();
-#endif
}
return s_currentMsg.wParam;
event.RequestMore(TRUE);
}
+ // If they are pending events, we must process them.
+#if wxUSE_THREADS
+ ProcessPendingEvents();
+#endif
s_inOnIdle = FALSE;
}
if ( !wxTheApp->DoMessage() )
break;
}
+ // If they are pending events, we must process them.
+#if wxUSE_THREADS
+ wxTheApp->ProcessPendingEvents();
+#endif
return TRUE;
}