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

Unified Diff: ash/test/ash_test_base.cc

Issue 2886253002: mash: remove more shell/shelf WmWindow usage. (Closed)
Patch Set: Fix WmShelf::ForWindow. Created 3 years, 7 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 | « ash/system/tray/system_tray_controller.cc ('k') | ash/wm/drag_window_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/test/ash_test_base.cc
diff --git a/ash/test/ash_test_base.cc b/ash/test/ash_test_base.cc
index 2c22ca48476a739fcd36ce4335b4e56900e445e8..0543347296a132f49578a1e5860cba8073b4189e 100644
--- a/ash/test/ash_test_base.cc
+++ b/ash/test/ash_test_base.cc
@@ -72,7 +72,6 @@ class AshEventGeneratorDelegate
display::Display display = screen->GetDisplayNearestPoint(point_in_screen);
return ShellPort::Get()
->GetRootWindowForDisplayId(display.id())
- ->aura_window()
->GetHost();
}
@@ -191,10 +190,7 @@ void AshTestBase::TearDown() {
// static
WmShelf* AshTestBase::GetPrimaryShelf() {
- return ShellPort::Get()
- ->GetPrimaryRootWindow()
- ->GetRootWindowController()
- ->GetShelf();
+ return Shell::GetPrimaryRootWindowController()->GetShelf();
}
// static
@@ -247,9 +243,7 @@ std::unique_ptr<views::Widget> AshTestBase::CreateTestWidget(
params.delegate = delegate;
params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET;
params.bounds = bounds;
- ShellPort::Get()
- ->GetPrimaryRootWindow()
- ->GetRootWindowController()
+ Shell::GetPrimaryRootWindowController()
->ConfigureWidgetInitParamsForContainer(widget.get(), container_id,
&params);
widget->Init(params);
@@ -363,9 +357,8 @@ aura::Window* AshTestBase::CreateTestWindowInShellWithDelegateAndType(
} else {
display::Display display =
display::Screen::GetScreen()->GetDisplayMatching(bounds);
- aura::Window* root = ShellPort::Get()
- ->GetRootWindowForDisplayId(display.id())
- ->aura_window();
+ aura::Window* root =
+ ShellPort::Get()->GetRootWindowForDisplayId(display.id());
gfx::Point origin = bounds.origin();
::wm::ConvertPointFromScreen(root, &origin);
window->SetBounds(gfx::Rect(origin, bounds.size()));
« no previous file with comments | « ash/system/tray/system_tray_controller.cc ('k') | ash/wm/drag_window_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698