From d412060d59b1597ae1d11d793662610e90863fc9 Mon Sep 17 00:00:00 2001 From: Tannin Date: Tue, 15 Jul 2014 17:31:44 +0200 Subject: - qt 5 compatibility fixes - detection for support of optimized find no longer depends on deprecated api --- src/ModOrganizer.pro | 6 +++--- src/dlls.manifest.debug.qt5 | 7 ++++--- src/dlls.manifest.qt5 | 1 + src/mainwindow.cpp | 1 - src/shared/directoryentry.cpp | 17 +++++++++++------ 5 files changed, 19 insertions(+), 13 deletions(-) (limited to 'src') diff --git a/src/ModOrganizer.pro b/src/ModOrganizer.pro index 4624ffec..13ec35b5 100644 --- a/src/ModOrganizer.pro +++ b/src/ModOrganizer.pro @@ -13,12 +13,12 @@ SUBDIRS = bsatk \ nxmhandler \ BossDummy \ pythonRunner \ - esptk \ - loot_cli + esptk# \ + #loot_cli plugins.depends = pythonRunner hookdll.depends = shared -organizer.depends = shared uibase plugins loot_cli +organizer.depends = shared uibase plugins# loot_cli CONFIG(debug, debug|release) { DESTDIR = outputd diff --git a/src/dlls.manifest.debug.qt5 b/src/dlls.manifest.debug.qt5 index 369539d1..6cc0a83d 100644 --- a/src/dlls.manifest.debug.qt5 +++ b/src/dlls.manifest.debug.qt5 @@ -1,11 +1,12 @@ - - - + + + + diff --git a/src/dlls.manifest.qt5 b/src/dlls.manifest.qt5 index 0a8ba7b8..5a22c2a8 100644 --- a/src/dlls.manifest.qt5 +++ b/src/dlls.manifest.qt5 @@ -7,6 +7,7 @@ + diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 9cbe9c40..81ef5880 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -978,7 +978,6 @@ bool MainWindow::eventFilter(QObject *object, QEvent *event) ((event->type() == QEvent::Leave) || (event->type() == QEvent::WindowDeactivate))) { hideSaveGameInfo(); } - return false; } diff --git a/src/shared/directoryentry.cpp b/src/shared/directoryentry.cpp index 5172346b..87431ea8 100644 --- a/src/shared/directoryentry.cpp +++ b/src/shared/directoryentry.cpp @@ -489,13 +489,18 @@ void DirectoryEntry::propagateOrigin(int origin) static bool SupportOptimizedFind() { - OSVERSIONINFO versionInfo; - versionInfo.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); - GetVersionEx(&versionInfo); - // large fetch and basic info for FindFirstFileEx is supported on win server 2008 r2, win 7 and newer - return (versionInfo.dwMajorVersion > 6) || - ((versionInfo.dwMajorVersion == 6) && (versionInfo.dwMinorVersion >= 1)); + + OSVERSIONINFOEX versionInfo; + versionInfo.dwOSVersionInfoSize = sizeof(OSVERSIONINFOEX); + versionInfo.dwMajorVersion = 6; + versionInfo.dwMinorVersion = 1; + ULONGLONG mask = ::VerSetConditionMask( + ::VerSetConditionMask(0, VER_MAJORVERSION, VER_GREATER_EQUAL), + VER_MINORVERSION, VER_GREATER_EQUAL); + + bool res = ::VerifyVersionInfo(&versionInfo, VER_MAJORVERSION | VER_MINORVERSION, mask); + return res; } -- cgit v1.3.1