Index: ui/base/layout.cc |
diff --git a/ui/base/layout.cc b/ui/base/layout.cc |
index aa3aecf55bd625d891f75339c8971406370f7e2f..726f86298986037d228873e199eefab88b9ab2ec 100644 |
--- a/ui/base/layout.cc |
+++ b/ui/base/layout.cc |
@@ -15,12 +15,12 @@ |
#include "ui/base/touch/touch_device.h" |
#include "ui/base/ui_base_switches.h" |
#include "ui/gfx/display.h" |
+#include "ui/gfx/dpi.h" |
#include "ui/gfx/image/image_skia.h" |
#include "ui/gfx/screen.h" |
#if defined(OS_WIN) |
#include "base/win/metro.h" |
-#include "ui/gfx/win/dpi.h" |
#include <Windows.h> |
#endif // defined(OS_WIN) |
@@ -83,9 +83,9 @@ ScaleFactor GetSupportedScaleFactor(float scale) { |
} |
float GetImageScale(ScaleFactor scale_factor) { |
-#if defined(OS_WIN) |
+#if defined(OS_WIN) || (defined(OS_LINUX) && !defined(OS_CHROMEOS)) |
if (gfx::IsHighDPIEnabled()) |
- return gfx::win::GetDeviceScaleFactor(); |
+ return gfx::GetDeviceScaleFactor(); |
#endif |
return GetScaleForScaleFactor(scale_factor); |
} |