Fix events on Windows
authorBlockMen <nmuelll@web.de>
Fri, 11 Dec 2015 21:40:37 +0000 (22:40 +0100)
committerBlockMen <nmuelll@web.de>
Fri, 11 Dec 2015 22:08:14 +0000 (23:08 +0100)
src/threading/event.cpp
src/threading/event.h

index 1c458bf1d78f068e20a8b9c225b54573dd5c6aea..c3c2ca029e4f45abf8a9bbad2f22a4ba6921e2d3 100644 (file)
@@ -25,14 +25,6 @@ DEALINGS IN THE SOFTWARE.
 
 #include "threading/event.h"
 
-#if defined(_WIN32)
-       #ifndef WIN32_LEAN_AND_MEAN
-               #define WIN32_LEAN_AND_MEAN
-       #endif
-       #include <windows.h>
-#endif
-
-
 #if __cplusplus < 201103L
 Event::Event()
 {
@@ -92,4 +84,3 @@ void Event::signal()
        pthread_mutex_unlock(&mutex);
 #endif
 }
-
index ea087e53f4ceb16452cd2e1c017efe42e6ff7990..dba3ddb4c28576c77d7f1c4613d34b7178470974 100644 (file)
@@ -30,7 +30,10 @@ DEALINGS IN THE SOFTWARE.
        #include <condition_variable>
        #include "threading/mutex.h"
 #elif defined(_WIN32)
-       #include <windef.h>
+       #ifndef WIN32_LEAN_AND_MEAN
+               #define WIN32_LEAN_AND_MEAN
+       #endif
+       #include <windows.h>
 #else
        #include <pthread.h>
 #endif
@@ -66,4 +69,3 @@ private:
 };
 
 #endif
-