Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1094)

Unified Diff: ui/gfx/screen_win.cc

Issue 11953054: Fix high-DPI on Windows to make use of DIP scaling in WebKit. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Remove experimental changes to resource handling. Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/gfx/screen_win.cc
diff --git a/ui/gfx/screen_win.cc b/ui/gfx/screen_win.cc
index 9b33c6b20024f5154671e19c4e3202ef20917952..c6fca87a02b137a886a49996bc933521dc2e8c05 100644
--- a/ui/gfx/screen_win.cc
+++ b/ui/gfx/screen_win.cc
@@ -36,7 +36,11 @@ ScreenWin::~ScreenWin() {
}
bool ScreenWin::IsDIPEnabled() {
+#if defined(ENABLE_HIDPI)
+ return true;
+#else
return false;
+#endif
}
gfx::Point ScreenWin::GetCursorScreenPoint() {
@@ -85,8 +89,10 @@ gfx::Display ScreenWin::GetPrimaryDisplay() const {
MONITORINFO mi = GetMonitorInfoForMonitor(
MonitorFromWindow(NULL, MONITOR_DEFAULTTOPRIMARY));
gfx::Display display = GetDisplay(mi);
+#if !defined(ENABLE_HIDPI)
pkotwicz 2013/01/23 19:39:23 Nit. This is up to you but you probably want a TOD
kevers 2013/01/23 21:37:00 Done.
DCHECK_EQ(GetSystemMetrics(SM_CXSCREEN), display.size().width());
DCHECK_EQ(GetSystemMetrics(SM_CYSCREEN), display.size().height());
+#endif
return display;
}

Powered by Google App Engine
This is Rietveld 408576698