Fix build on non-windows

This commit is contained in:
Marco Bartoli 2024-12-15 23:00:30 +01:00 committed by GitHub
parent 45d7e6576d
commit d6525e7907
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -59,7 +59,9 @@
#include <algorithm> #include <algorithm>
#if defined(Q_OS_WIN)
#include "../../plugins/platforms/windows/vxkex.h" #include "../../plugins/platforms/windows/vxkex.h"
#endif
QT_BEGIN_NAMESPACE QT_BEGIN_NAMESPACE
@ -256,8 +258,10 @@ void QWindowsStyle::polish(QPalette &pal)
QCommonStyle::polish(pal); QCommonStyle::polish(pal);
} }
#if defined(Q_OS_WIN)
typedef BOOL (WINAPI *GetSystemMetricsForDpiFunc)(int, UINT); typedef BOOL (WINAPI *GetSystemMetricsForDpiFunc)(int, UINT);
typedef BOOL (WINAPI *SystemParametersInfoForDpiFunc)(UINT, UINT, PVOID, UINT, UINT); typedef BOOL (WINAPI *SystemParametersInfoForDpiFunc)(UINT, UINT, PVOID, UINT, UINT);
#endif
int QWindowsStylePrivate::pixelMetricFromSystemDp(QStyle::PixelMetric pm, const QStyleOption *, const QWidget *widget) int QWindowsStylePrivate::pixelMetricFromSystemDp(QStyle::PixelMetric pm, const QStyleOption *, const QWidget *widget)
{ {