Index: ui/aura/remote_window_tree_host_win.cc |
diff --git a/ui/aura/remote_window_tree_host_win.cc b/ui/aura/remote_window_tree_host_win.cc |
index 70412d33546cb81bf87b47e25d8fb223fe4d2c3a..31aa55121833b7b916605f380e11eb04e2f79272 100644 |
--- a/ui/aura/remote_window_tree_host_win.cc |
+++ b/ui/aura/remote_window_tree_host_win.cc |
@@ -183,8 +183,11 @@ bool RemoteWindowTreeHostWin::IsValid() { |
return Instance()->remote_window_ != NULL; |
} |
-void RemoteWindowTreeHostWin::SetRemoteWindowHandle(HWND remote_window) { |
+void RemoteWindowTreeHostWin::InitializeRemoteWindowAndScaleFactor( |
+ HWND remote_window, |
+ float device_scale) { |
remote_window_ = remote_window; |
+ gfx::InitDeviceScaleFactor(device_scale); |
// Do not create compositor here, but in Connected() below. |
// See http://crbug.com/330179 and http://crbug.com/334380. |
} |
@@ -489,7 +492,7 @@ void RemoteWindowTreeHostWin::OnTextInputClientUpdated( |
} |
gfx::Point PointFromNativeEvent(int32 x, int32 y) { |
- static float scale_factor = gfx::GetModernUIScale(); |
+ static float scale_factor = gfx::GetDPIScale(); |
gfx::Point result( x * scale_factor, y * scale_factor); |
return result; |
} |