Check if _WIN32_IE is defined with proper value in window_w32.cpp
authorArtur Wieczorek <artwik@wp.pl>
Wed, 31 Dec 2014 09:15:48 +0000 (10:15 +0100)
committerArtur Wieczorek <artwik@wp.pl>
Wed, 14 Jan 2015 13:52:32 +0000 (14:52 +0100)
TBBUTTONINFO struct and BTNS_xxx symbols used in the code need _WIN32_IE to be defined with at least 0x0500 value (_WIN32_IE_IE50) in order to be included from commctrl.h.

modules/highgui/src/window_w32.cpp

index 66e6846..0878bff 100644 (file)
 #  pragma GCC diagnostic ignored "-Wmissing-declarations"
 #endif
 
+#if (_WIN32_IE < 0x0500)
+#pragma message("WARNING: Win32 UI needs to be compiled with _WIN32_IE >= 0x0500 (_WIN32_IE_IE50)")
+#define _WIN32_IE 0x0500
+#endif
+
 #include <commctrl.h>
 #include <stdlib.h>
 #include <string.h>