summaryrefslogtreecommitdiff
path: root/Source/Core/DolphinQt/Config/ControllersWindow.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Core/DolphinQt/Config/ControllersWindow.cpp')
-rw-r--r--Source/Core/DolphinQt/Config/ControllersWindow.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/Source/Core/DolphinQt/Config/ControllersWindow.cpp b/Source/Core/DolphinQt/Config/ControllersWindow.cpp
index 2f3d03ed43..82e6da599b 100644
--- a/Source/Core/DolphinQt/Config/ControllersWindow.cpp
+++ b/Source/Core/DolphinQt/Config/ControllersWindow.cpp
@@ -131,9 +131,12 @@ static int GetLayoutHorizontalSpacing(const QGridLayout* layout)
// Docs claim this is deprecated, but on macOS with Qt 5.8 this is the only one that actually
// works.
float pixel_ratio = QGuiApplication::primaryScreen()->devicePixelRatio();
+#ifdef __APPLE__
+ // TODO is this still required?
hspacing = pixel_ratio * style->pixelMetric(QStyle::PM_DefaultLayoutSpacing);
if (hspacing >= 0)
return hspacing;
+#endif
// Ripped from qtbase/src/widgets/styles/qcommonstyle.cpp
return pixel_ratio * 6;