| Index: ash/accelerators/accelerator_interactive_uitest_chromeos.cc
|
| diff --git a/ash/accelerators/accelerator_interactive_uitest_chromeos.cc b/ash/accelerators/accelerator_interactive_uitest_chromeos.cc
|
| index cee9816af976762298f3f879496691f3f69c1cb7..58d237407f2110f42a399c51569f0bfc19972fbf 100644
|
| --- a/ash/accelerators/accelerator_interactive_uitest_chromeos.cc
|
| +++ b/ash/accelerators/accelerator_interactive_uitest_chromeos.cc
|
| @@ -5,12 +5,12 @@
|
| #include "ash/accelerators/accelerator_controller.h"
|
|
|
| #include "ash/common/shell_observer.h"
|
| +#include "ash/common/system/chromeos/network/network_observer.h"
|
| #include "ash/common/system/tray/system_tray_delegate.h"
|
| +#include "ash/common/system/tray/system_tray_notifier.h"
|
| #include "ash/common/wm/window_state.h"
|
| #include "ash/common/wm_shell.h"
|
| #include "ash/shell.h"
|
| -#include "ash/system/chromeos/network/network_observer.h"
|
| -#include "ash/system/tray/system_tray_notifier.h"
|
| #include "ash/test/ash_interactive_ui_test_base.h"
|
| #include "ash/test/test_screenshot_delegate.h"
|
| #include "ash/test/test_volume_control_delegate.h"
|
| @@ -79,8 +79,9 @@ class AcceleratorInteractiveUITest : public AshInteractiveUITestBase,
|
| bool shift,
|
| bool alt) {
|
| base::RunLoop loop;
|
| - ui_controls::SendKeyPressNotifyWhenDone(root_window(), key, control, shift,
|
| - alt, false, loop.QuitClosure());
|
| + ui_controls::SendKeyPressNotifyWhenDone(Shell::GetPrimaryRootWindow(), key,
|
| + control, shift, alt, false,
|
| + loop.QuitClosure());
|
| loop.Run();
|
| }
|
|
|
| @@ -88,9 +89,6 @@ class AcceleratorInteractiveUITest : public AshInteractiveUITestBase,
|
| void OnOverviewModeStarting() override { is_in_overview_mode_ = true; }
|
| void OnOverviewModeEnded() override { is_in_overview_mode_ = false; }
|
|
|
| - Shell* shell() const { return Shell::GetInstance(); }
|
| - aura::Window* root_window() const { return Shell::GetPrimaryRootWindow(); }
|
| -
|
| protected:
|
| bool is_in_overview_mode_;
|
|
|
| @@ -186,7 +184,7 @@ TEST_F(AcceleratorInteractiveUITest, MAYBE_ChromeOsAccelerators) {
|
|
|
| // Test TOGGLE_WIFI.
|
| TestNetworkObserver network_observer;
|
| - shell()->system_tray_notifier()->AddNetworkObserver(&network_observer);
|
| + WmShell::Get()->system_tray_notifier()->AddNetworkObserver(&network_observer);
|
|
|
| EXPECT_FALSE(network_observer.wifi_enabled_status());
|
| SendKeyPressSync(ui::VKEY_WLAN, false, false, false);
|
| @@ -194,16 +192,17 @@ TEST_F(AcceleratorInteractiveUITest, MAYBE_ChromeOsAccelerators) {
|
| SendKeyPressSync(ui::VKEY_WLAN, false, false, false);
|
| EXPECT_FALSE(network_observer.wifi_enabled_status());
|
|
|
| - shell()->system_tray_notifier()->RemoveNetworkObserver(&network_observer);
|
| + WmShell::Get()->system_tray_notifier()->RemoveNetworkObserver(
|
| + &network_observer);
|
| }
|
|
|
| // Tests the app list accelerator.
|
| TEST_F(AcceleratorInteractiveUITest, MAYBE_ToggleAppList) {
|
| - EXPECT_FALSE(shell()->GetAppListTargetVisibility());
|
| + EXPECT_FALSE(Shell::GetInstance()->GetAppListTargetVisibility());
|
| SendKeyPressSync(ui::VKEY_LWIN, false, false, false);
|
| - EXPECT_TRUE(shell()->GetAppListTargetVisibility());
|
| + EXPECT_TRUE(Shell::GetInstance()->GetAppListTargetVisibility());
|
| SendKeyPressSync(ui::VKEY_LWIN, false, false, false);
|
| - EXPECT_FALSE(shell()->GetAppListTargetVisibility());
|
| + EXPECT_FALSE(Shell::GetInstance()->GetAppListTargetVisibility());
|
| }
|
|
|
| } // namespace test
|
|
|