From 88d7112796be37d4e1feb0015cfe95c6f39f303c Mon Sep 17 00:00:00 2001 From: "oshima@chromium.org" Date: Thu, 18 Oct 2012 07:11:01 +0000 Subject: Remove Shell::shelf|status_area_widget|launcher and updated all clients to use one on RootWindowController and/or Launcher::ForPrimaryDisplay/ForWindow. BUG=145978 Review URL: https://chromiumcodereview.appspot.com/11017079 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@162664 0039d316-1c4b-4281-b951-d872f2087c98 --- ash/shell_unittest.cc | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) (limited to 'ash/shell_unittest.cc') diff --git a/ash/shell_unittest.cc b/ash/shell_unittest.cc index 131d500..d939cdb 100644 --- a/ash/shell_unittest.cc +++ b/ash/shell_unittest.cc @@ -10,6 +10,7 @@ #include "ash/ash_switches.h" #include "ash/desktop_background/desktop_background_widget_controller.h" #include "ash/launcher/launcher.h" +#include "ash/root_window_controller.h" #include "ash/shell_delegate.h" #include "ash/shell_window_ids.h" #include "ash/test/ash_test_base.h" @@ -277,7 +278,7 @@ TEST_F(ShellTest, MAYBE_ManagedWindowModeBasics) { // We start with the usual window containers. ExpectAllContainers(); // Launcher is visible. - views::Widget* launcher_widget = shell->launcher()->widget(); + views::Widget* launcher_widget = Launcher::ForPrimaryDisplay()->widget(); EXPECT_TRUE(launcher_widget->IsVisible()); // Launcher is at bottom-left of screen. EXPECT_EQ(0, launcher_widget->GetWindowBoundsInScreen().x()); @@ -316,18 +317,21 @@ TEST_F(ShellTest, FullscreenWindowHidesShelf) { EXPECT_FALSE(widget->IsMaximized()); // Shelf defaults to visible. - EXPECT_EQ(internal::ShelfLayoutManager::VISIBLE, - Shell::GetInstance()->shelf()->visibility_state()); + EXPECT_EQ( + internal::ShelfLayoutManager::VISIBLE, + Shell::GetPrimaryRootWindowController()->shelf()->visibility_state()); // Fullscreen window hides it. widget->SetFullscreen(true); - EXPECT_EQ(internal::ShelfLayoutManager::HIDDEN, - Shell::GetInstance()->shelf()->visibility_state()); + EXPECT_EQ( + internal::ShelfLayoutManager::HIDDEN, + Shell::GetPrimaryRootWindowController()->shelf()->visibility_state()); // Restoring the window restores it. widget->Restore(); - EXPECT_EQ(internal::ShelfLayoutManager::VISIBLE, - Shell::GetInstance()->shelf()->visibility_state()); + EXPECT_EQ( + internal::ShelfLayoutManager::VISIBLE, + Shell::GetPrimaryRootWindowController()->shelf()->visibility_state()); // Clean up. widget->Close(); -- cgit v1.1