From f94e9b1e743c538cc7ff86580b7cfce0b50bbd59 Mon Sep 17 00:00:00 2001 From: aliaspider Date: Fri, 23 Mar 2018 22:54:12 +0100 Subject: [PATCH] set _WIN32_WINNT to 0x0601 in stdafx.h --- CMakeLists.txt | 1 - Common/stdafx.h | 4 ++-- Windows/DinputDevice.cpp | 2 ++ Windows/MainWindow.cpp | 2 +- Windows/TouchInputHandler.cpp | 2 +- Windows/main.cpp | 1 + Windows/stdafx.h | 17 ++++++++++++----- 7 files changed, 19 insertions(+), 10 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 18e8f1be7..737490706 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -432,7 +432,6 @@ if(WIN32) set(CMAKE_RC_COMPILE_OBJECT " -O coff ") # required when using the dx9sdk include paths add_definitions(-include ${CMAKE_CURRENT_SOURCE_DIR}/Windows/mingw_defines.h) - add_definitions(-D_WIN32_WINNT=0x0601) else() target_link_libraries(Common dxguid) endif() diff --git a/Common/stdafx.h b/Common/stdafx.h index 7150e018a..1f18c24ec 100644 --- a/Common/stdafx.h +++ b/Common/stdafx.h @@ -23,13 +23,13 @@ #if defined(_MSC_VER) && _MSC_VER < 1700 #error You need a newer version of Visual Studio. #else -#define _WIN32_WINNT 0x600 +#define _WIN32_WINNT 0x601 #endif #endif // #ifndef _WIN32_WINNT #undef WINVER -#define WINVER 0x0600 +#define WINVER _WIN32_WINNT #ifndef _WIN32_IE #define _WIN32_IE 0x0600 // Default value is 0x0400 #endif diff --git a/Windows/DinputDevice.cpp b/Windows/DinputDevice.cpp index 8d0f2cd95..7a67e976a 100644 --- a/Windows/DinputDevice.cpp +++ b/Windows/DinputDevice.cpp @@ -15,8 +15,10 @@ // Official git repository and contact information can be found at // https://github.com/hrydgard/ppsspp and http://www.ppsspp.org/. +#include "stdafx.h" #include #include +#include #include "Core/HLE/sceCtrl.h" #include "DinputDevice.h" diff --git a/Windows/MainWindow.cpp b/Windows/MainWindow.cpp index f15bcfe3a..67a820042 100644 --- a/Windows/MainWindow.cpp +++ b/Windows/MainWindow.cpp @@ -20,7 +20,7 @@ // NOTE: Apologies for the quality of this code, this is really from pre-opensource Dolphin - that is, 2003. // It's improving slowly, though. :) - +#include "stdafx.h" #include "Common/CommonWindows.h" #include "Common/KeyMap.h" #include "Common/OSVersion.h" diff --git a/Windows/TouchInputHandler.cpp b/Windows/TouchInputHandler.cpp index c12933264..b4f4bd38c 100644 --- a/Windows/TouchInputHandler.cpp +++ b/Windows/TouchInputHandler.cpp @@ -1,4 +1,4 @@ -#define NOMINMAX +#include "stdafx.h" #include #include "Windows/TouchInputHandler.h" diff --git a/Windows/main.cpp b/Windows/main.cpp index 0e9259b93..cf04660d4 100644 --- a/Windows/main.cpp +++ b/Windows/main.cpp @@ -15,6 +15,7 @@ // Official git repository and contact information can be found at // https://github.com/hrydgard/ppsspp and http://www.ppsspp.org/. +#include "stdafx.h" #include #include diff --git a/Windows/stdafx.h b/Windows/stdafx.h index cdf906502..a7f4a4928 100644 --- a/Windows/stdafx.h +++ b/Windows/stdafx.h @@ -19,19 +19,16 @@ #pragma warning(disable:4996) -// WinSock2 MUST be included before !!! -#include - #undef _WIN32_WINNT #if defined(_MSC_VER) && _MSC_VER < 1700 #error You need a newer version of Visual Studio #else -#define _WIN32_WINNT 0x600 // Compile for Vista on Visual Studio 2012 and above +#define _WIN32_WINNT 0x601 // Compile for Win7 on Visual Studio 2012 and above #endif #undef WINVER -#define WINVER 0x0600 +#define WINVER _WIN32_WINNT #ifndef _WIN32_IE #define _WIN32_IE 0x0600 // Default value is 0x0400 #endif @@ -47,6 +44,16 @@ #pragma comment(linker,"/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='*' publicKeyToken='6595b64144ccf1df' language='*'\"") #endif +#ifndef WIN32_LEAN_AND_MEAN +#define WIN32_LEAN_AND_MEAN +#endif +#ifndef NOMINMAX +#define NOMINMAX +#endif + +// WinSock2 MUST be included before !!! +#include + #include "Common/CommonWindows.h" #include