summaryrefslogtreecommitdiffstats
path: root/src/corelib
diff options
context:
space:
mode:
authorYuhang Zhao <2546789017@qq.com>2021-10-17 11:19:48 +0800
committerYuhang Zhao <2546789017@qq.com>2021-11-10 20:31:05 +0800
commit6652bf2353d807f724f398a15cb22c188830f57c (patch)
treef3728b8e582a49ab46b2417d1f28fb2f430c2dfa /src/corelib
parenta8be40bd64b9258334d6936b1775bc6631fd158d (diff)
Bump WINVER, _WIN32_WINNT and _WIN32_IE to _WIN32_WINNT_WIN10 (0x0A00)
And bump NTDDI_VERSION to 0x0A00000B (NTDDI_WIN10_CO) at the same time, to unblock the developers from accessing the latest Windows APIs. Pick-to: 6.2 Change-Id: Ifbc28c8f8b073866871685c020301f5f20dc9591 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib')
-rw-r--r--src/corelib/global/qt_windows.h29
-rw-r--r--src/corelib/io/qfilesystemengine_win.cpp9
2 files changed, 11 insertions, 27 deletions
diff --git a/src/corelib/global/qt_windows.h b/src/corelib/global/qt_windows.h
index 7ffe313f00..15255b9434 100644
--- a/src/corelib/global/qt_windows.h
+++ b/src/corelib/global/qt_windows.h
@@ -45,17 +45,17 @@
#pragma qt_sync_stop_processing
#endif
-#if defined(Q_CC_MINGW)
-// mingw's windows.h does not set _WIN32_WINNT, resulting breaking compilation
-# ifndef WINVER
-# define WINVER 0x601
-# endif
-# ifndef _WIN32_WINNT
-# define _WIN32_WINNT 0x601
-# endif
-# ifndef NTDDI_VERSION
-# define NTDDI_VERSION 0x06010000
-# endif
+#ifndef WINVER
+# define WINVER 0x0A00 // _WIN32_WINNT_WIN10
+#endif
+#ifndef _WIN32_WINNT
+# define _WIN32_WINNT 0x0A00
+#endif
+#ifndef _WIN32_IE
+# define _WIN32_IE 0x0A00
+#endif
+#ifndef NTDDI_VERSION
+# define NTDDI_VERSION 0x0A00000B // NTDDI_WIN10_CO
#endif
#ifndef NOMINMAX
@@ -63,13 +63,6 @@
#endif
#include <windows.h>
-#if defined(_WIN32_IE) && _WIN32_IE < 0x0501
-# undef _WIN32_IE
-#endif
-#if !defined(_WIN32_IE)
-# define _WIN32_IE 0x0501
-#endif
-
// already defined when compiled with WINVER >= 0x0500
#ifndef SPI_SETMENUANIMATION
#define SPI_SETMENUANIMATION 0x1003
diff --git a/src/corelib/io/qfilesystemengine_win.cpp b/src/corelib/io/qfilesystemengine_win.cpp
index 9e009a05e7..d2da2082fa 100644
--- a/src/corelib/io/qfilesystemengine_win.cpp
+++ b/src/corelib/io/qfilesystemengine_win.cpp
@@ -627,15 +627,6 @@ QFileSystemEntry QFileSystemEngine::absoluteName(const QFileSystemEntry &entry)
return QFileSystemEntry(ret, QFileSystemEntry::FromInternalPath());
}
-#if defined(Q_CC_MINGW) && WINVER < 0x0602 && _WIN32_WINNT < _WIN32_WINNT_WIN8 // Windows 8 onwards
-
-typedef struct _FILE_ID_INFO {
- ULONGLONG VolumeSerialNumber;
- FILE_ID_128 FileId;
-} FILE_ID_INFO, *PFILE_ID_INFO;
-
-#endif // if defined(Q_CC_MINGW) && WINVER < 0x0602 && _WIN32_WINNT < _WIN32_WINNT_WIN8
-
// File ID for Windows up to version 7 and FAT32 drives
static inline QByteArray fileId(HANDLE handle)
{