git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15897
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
{
// set flag for wxIsWaitingForThread()
gs_waitingForThread = TRUE;
{
// set flag for wxIsWaitingForThread()
gs_waitingForThread = TRUE;
-
-#if wxUSE_GUI
- wxBeginBusyCursor();
-#endif // wxUSE_GUI
}
// ask the thread to terminate
}
// ask the thread to terminate
+ if ( IsMain() )
+ {
+ // give the thread we're waiting for chance to do the GUI call
+ // it might be in
+ if ( (gs_nWaitingForGui > 0) && wxGuiOwnedByMainThread() )
+ {
+ wxMutexGuiLeave();
+ }
+ }
+
result = ::MsgWaitForMultipleObjects
(
1, // number of objects to wait for
&hThread, // the objects
FALSE, // don't wait for all objects
INFINITE, // no timeout
result = ::MsgWaitForMultipleObjects
(
1, // number of objects to wait for
&hThread, // the objects
FALSE, // don't wait for all objects
INFINITE, // no timeout
- QS_ALLEVENTS // return as soon as there are any events
+ QS_ALLINPUT | // return as soon as there are any events
+ QS_ALLPOSTMESSAGE
return wxTHREAD_KILLED;
}
return wxTHREAD_KILLED;
}
-
- if ( IsMain() )
- {
- // give the thread we're waiting for chance to exit
- // from the GUI call it might have been in
- if ( (gs_nWaitingForGui > 0) && wxGuiOwnedByMainThread() )
- {
- wxMutexGuiLeave();
- }
- }
-
if ( IsMain() )
{
gs_waitingForThread = FALSE;
if ( IsMain() )
{
gs_waitingForThread = FALSE;
-
-#if wxUSE_GUI
- wxEndBusyCursor();
-#endif // wxUSE_GUI