|
|
@@ -49,6 +49,10 @@
|
|
|
#include "callbackGraphicsWindow.h"
|
|
|
#include "depthTestAttrib.h"
|
|
|
|
|
|
+#if defined(_WIN32) && defined(HAVE_THREADS) && defined(SIMPLE_THREADS)
|
|
|
+#include "winInputDeviceManager.h"
|
|
|
+#endif
|
|
|
+
|
|
|
#if defined(WIN32)
|
|
|
#define WINDOWS_LEAN_AND_MEAN
|
|
|
#include <WinSock2.h>
|
|
|
@@ -637,6 +641,12 @@ remove_all_windows() {
|
|
|
PStatClient::get_global_pstats()->disconnect();
|
|
|
#endif
|
|
|
|
|
|
+#if defined(_WIN32) && defined(HAVE_THREADS) && defined(SIMPLE_THREADS)
|
|
|
+ // Send a message to the input message pump asking it to shut itself down.
|
|
|
+ // If we don't do that, the next call will deadlock.
|
|
|
+ WinInputDeviceManager::stop_thread();
|
|
|
+#endif
|
|
|
+
|
|
|
// Well, and why not clean up all threads here?
|
|
|
Thread::prepare_for_exit();
|
|
|
}
|