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

Unified Diff: ui/views/win/hwnd_util_aurawin.cc

Issue 37733003: Make GetRootWindow() return a Window instead of a RootWindow. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 years, 2 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
« no previous file with comments | « ui/views/widget/widget_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/win/hwnd_util_aurawin.cc
diff --git a/ui/views/win/hwnd_util_aurawin.cc b/ui/views/win/hwnd_util_aurawin.cc
index 606247893650f6633d49c723f4b54c56b9bacb00..a927df1ee8e8d14f32ac8e77134382b113fa5566 100644
--- a/ui/views/win/hwnd_util_aurawin.cc
+++ b/ui/views/win/hwnd_util_aurawin.cc
@@ -19,21 +19,21 @@ HWND HWNDForWidget(const Widget* widget) {
HWND HWNDForNativeView(const gfx::NativeView view) {
return view && view->GetRootWindow() ?
- view->GetRootWindow()->GetAcceleratedWidget() : NULL;
+ view->GetDispatcher()->GetAcceleratedWidget() : NULL;
}
HWND HWNDForNativeWindow(const gfx::NativeWindow window) {
return window && window->GetRootWindow() ?
- window->GetRootWindow()->GetAcceleratedWidget() : NULL;
+ window->GetDispatcher()->GetAcceleratedWidget() : NULL;
}
gfx::Rect GetWindowBoundsForClientBounds(View* view,
const gfx::Rect& client_bounds) {
DCHECK(view);
- aura::RootWindow* window =
- view->GetWidget()->GetNativeWindow()->GetRootWindow();
- if (window) {
- HWND hwnd = window->GetAcceleratedWidget();
+ aura::WindowEventDispatcher* dispatcher =
+ view->GetWidget()->GetNativeWindow()->GetDispatcher();
+ if (dispatcher) {
+ HWND hwnd = dispatcher->GetAcceleratedWidget();
RECT rect = client_bounds.ToRECT();
DWORD style = ::GetWindowLong(hwnd, GWL_STYLE);
DWORD ex_style = ::GetWindowLong(hwnd, GWL_EXSTYLE);
« no previous file with comments | « ui/views/widget/widget_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698