diff --git a/include/FramelessHelper/Core/private/framelesshelpercore_global_p.h b/include/FramelessHelper/Core/private/framelesshelpercore_global_p.h index 892e041..4ce2607 100644 --- a/include/FramelessHelper/Core/private/framelesshelpercore_global_p.h +++ b/include/FramelessHelper/Core/private/framelesshelpercore_global_p.h @@ -117,7 +117,7 @@ enum class ExtraDataType : quint8 }; #if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) -inline uint qHash(ExtraDataType key, uint seed = 0) noexcept { +inline uint qHash(const ExtraDataType key, const uint seed = 0) noexcept { return ::qHash(static_cast(key), seed); } #endif diff --git a/src/core/utils_win.cpp b/src/core/utils_win.cpp index 459f335..c65bc1c 100644 --- a/src/core/utils_win.cpp +++ b/src/core/utils_win.cpp @@ -1221,9 +1221,9 @@ QString Utils::getSystemErrorMessage(const QString &function) if (function.isEmpty()) { return {}; } - const DWORD code = GetLastError(); + const DWORD code = ::GetLastError(); if (code == ERROR_SUCCESS) { - return {}; + return kSuccessMessageText; } return getSystemErrorMessageImpl(function, code); }