aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRémi Verschelde2017-01-08 20:41:11 +0100
committerRémi Verschelde2017-01-12 19:15:30 +0100
commitd66740175eef6f67f2edb364533fa71eaad5ceb7 (patch)
treeb4daa3744d7c39a9366344b63e4bd53840903293
parent5672852351d9d47c848bafad14bb031f176b8558 (diff)
downloadgodot-d66740175eef6f67f2edb364533fa71eaad5ceb7.tar.gz
godot-d66740175eef6f67f2edb364533fa71eaad5ceb7.tar.zst
godot-d66740175eef6f67f2edb364533fa71eaad5ceb7.zip
-rw-r--r--drivers/unix/ip_unix.cpp12
-rw-r--r--drivers/windows/file_access_windows.cpp2
-rw-r--r--platform/windows/context_gl_win.cpp1
-rw-r--r--platform/windows/detect.py4
-rw-r--r--platform/windows/key_mapping_win.cpp2
-rw-r--r--platform/windows/os_windows.cpp2
-rw-r--r--platform/windows/os_windows.h2
7 files changed, 9 insertions, 16 deletions
diff --git a/drivers/unix/ip_unix.cpp b/drivers/unix/ip_unix.cpp
index 200eb1dd2..ed11c0686 100644
--- a/drivers/unix/ip_unix.cpp
+++ b/drivers/unix/ip_unix.cpp
@@ -37,19 +37,13 @@
#ifndef AI_ADDRCONFIG
#define AI_ADDRCONFIG 0x00000400
#endif
- #ifdef WINRT_ENABLED
#include <ws2tcpip.h>
#include <winsock2.h>
#include <windows.h>
#include <stdio.h>
- #else
- #define WINVER 0x0600
- #include <ws2tcpip.h>
- #include <winsock2.h>
- #include <windows.h>
- #include <stdio.h>
- #include <iphlpapi.h>
- #endif
+ #ifndef WINRT_ENABLED
+ #include <iphlpapi.h>
+ #endif
#else
#include <netdb.h>
#ifdef ANDROID_ENABLED
diff --git a/drivers/windows/file_access_windows.cpp b/drivers/windows/file_access_windows.cpp
index 73beb89eb..c9edb7b09 100644
--- a/drivers/windows/file_access_windows.cpp
+++ b/drivers/windows/file_access_windows.cpp
@@ -28,8 +28,6 @@
/*************************************************************************/
#ifdef WINDOWS_ENABLED
-#define WINVER 0x0500
-
#include <windows.h>
#include "shlwapi.h"
#include "file_access_windows.h"
diff --git a/platform/windows/context_gl_win.cpp b/platform/windows/context_gl_win.cpp
index 14d7dbf34..6c3760fd4 100644
--- a/platform/windows/context_gl_win.cpp
+++ b/platform/windows/context_gl_win.cpp
@@ -40,7 +40,6 @@
//
//
-#define WINVER 0x0500
#include "context_gl_win.h"
//#include "drivers/opengl/glwrapper.h"
diff --git a/platform/windows/detect.py b/platform/windows/detect.py
index 77653b22a..74806a260 100644
--- a/platform/windows/detect.py
+++ b/platform/windows/detect.py
@@ -198,6 +198,10 @@ def build_res_file(target, source, env):
def configure(env):
env.Append(CPPPATH=['#platform/windows'])
+
+ # Targeted Windows version: Vista (and later)
+ env.Append(CPPFLAGS=['-D_WIN32_WINNT=0x0600'])
+
env['is_mingw'] = False
if (os.name == "nt" and os.getenv("VSINSTALLDIR") != None):
# build using visual studio
diff --git a/platform/windows/key_mapping_win.cpp b/platform/windows/key_mapping_win.cpp
index 00a0ca79c..9ab222e9e 100644
--- a/platform/windows/key_mapping_win.cpp
+++ b/platform/windows/key_mapping_win.cpp
@@ -26,8 +26,8 @@
/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/*************************************************************************/
-#define WINVER 0x0500
#include "key_mapping_win.h"
+
#include <stdio.h>
struct _WinTranslatePair {
diff --git a/platform/windows/os_windows.cpp b/platform/windows/os_windows.cpp
index 32f7d9c54..fac067fcd 100644
--- a/platform/windows/os_windows.cpp
+++ b/platform/windows/os_windows.cpp
@@ -686,7 +686,7 @@ LRESULT OS_Windows::WndProc(HWND hWnd,UINT uMsg, WPARAM wParam, LPARAM lParam) {
print_line("input lang change");
} break;
- #if WINVER >= 0x0700 // for windows 7
+ #if WINVER >= 0x0601 // for windows 7
case WM_TOUCH: {
BOOL bHandled = FALSE;
diff --git a/platform/windows/os_windows.h b/platform/windows/os_windows.h
index 435e82c45..575dc3792 100644
--- a/platform/windows/os_windows.h
+++ b/platform/windows/os_windows.h
@@ -29,8 +29,6 @@
#ifndef OS_WINDOWS_H
#define OS_WINDOWS_H
-#define WINVER 0x0600
-
#include "os/input.h"
#include "os/os.h"
#include "context_gl_win.h"