Index: ash/host/ash_window_tree_host_win.cc |
diff --git a/ash/host/ash_window_tree_host_win.cc b/ash/host/ash_window_tree_host_win.cc |
index e69769ca6a55fe8e3f789ad0bfb5c5252ccd98e4..203a5a7145465a06efdc2929dfbb9fd93c001180 100644 |
--- a/ash/host/ash_window_tree_host_win.cc |
+++ b/ash/host/ash_window_tree_host_win.cc |
@@ -13,7 +13,7 @@ |
#include "ash/ime/input_method_event_handler.h" |
#include "base/command_line.h" |
#include "base/win/windows_version.h" |
-#include "ui/aura/window_tree_host_win.h" |
+#include "ui/aura/window_tree_host_platform.h" |
#include "ui/events/event_processor.h" |
#include "ui/gfx/geometry/insets.h" |
#include "ui/gfx/transform.h" |
@@ -22,10 +22,10 @@ namespace ash { |
namespace { |
class AshWindowTreeHostWin : public AshWindowTreeHost, |
- public aura::WindowTreeHostWin { |
+ public aura::WindowTreeHostPlatform { |
public: |
explicit AshWindowTreeHostWin(const gfx::Rect& initial_bounds) |
- : aura::WindowTreeHostWin(initial_bounds), |
+ : aura::WindowTreeHostPlatform(initial_bounds), |
fullscreen_(false), |
saved_window_style_(0), |
saved_window_ex_style_(0), |
@@ -40,29 +40,33 @@ class AshWindowTreeHostWin : public AshWindowTreeHost, |
gfx::Rect target_rect; |
if (!fullscreen_) { |
fullscreen_ = true; |
- saved_window_style_ = GetWindowLong(hwnd(), GWL_STYLE); |
- saved_window_ex_style_ = GetWindowLong(hwnd(), GWL_EXSTYLE); |
- GetWindowRect(hwnd(), &saved_window_rect_); |
- SetWindowLong(hwnd(), |
+ saved_window_style_ = GetWindowLong(GetAcceleratedWidget(), GWL_STYLE); |
mfomitchev
2015/10/09 21:24:18
hwnd = GetAcceleratedWidget() so that we don't cal
no sievers
2015/10/09 21:41:14
Done.
|
+ saved_window_ex_style_ = |
+ GetWindowLong(GetAcceleratedWidget(), GWL_EXSTYLE); |
+ GetWindowRect(GetAcceleratedWidget(), &saved_window_rect_); |
+ SetWindowLong(GetAcceleratedWidget(), |
GWL_STYLE, |
saved_window_style_ & ~(WS_CAPTION | WS_THICKFRAME)); |
SetWindowLong( |
- hwnd(), |
+ GetAcceleratedWidget(), |
GWL_EXSTYLE, |
saved_window_ex_style_ & ~(WS_EX_DLGMODALFRAME | WS_EX_WINDOWEDGE | |
WS_EX_CLIENTEDGE | WS_EX_STATICEDGE)); |
MONITORINFO mi; |
mi.cbSize = sizeof(mi); |
- GetMonitorInfo(MonitorFromWindow(hwnd(), MONITOR_DEFAULTTONEAREST), &mi); |
+ GetMonitorInfo( |
+ MonitorFromWindow(GetAcceleratedWidget(), MONITOR_DEFAULTTONEAREST), |
+ &mi); |
target_rect = gfx::Rect(mi.rcMonitor); |
} else { |
fullscreen_ = false; |
- SetWindowLong(hwnd(), GWL_STYLE, saved_window_style_); |
- SetWindowLong(hwnd(), GWL_EXSTYLE, saved_window_ex_style_); |
+ SetWindowLong(GetAcceleratedWidget(), GWL_STYLE, saved_window_style_); |
+ SetWindowLong(GetAcceleratedWidget(), GWL_EXSTYLE, |
+ saved_window_ex_style_); |
target_rect = gfx::Rect(saved_window_rect_); |
} |
- SetWindowPos(hwnd(), |
+ SetWindowPos(GetAcceleratedWidget(), |
NULL, |
target_rect.x(), |
target_rect.y(), |