| Index: ash/system/chromeos/rotation/tray_rotation_lock_unittest.cc
|
| diff --git a/ash/system/chromeos/rotation/tray_rotation_lock_unittest.cc b/ash/system/chromeos/rotation/tray_rotation_lock_unittest.cc
|
| index c043a065e148c8c7f266a4a5129a40e5f4a9b203..5a04e2e41e986ad8a34aab9d6d4354c9be75fc2a 100644
|
| --- a/ash/system/chromeos/rotation/tray_rotation_lock_unittest.cc
|
| +++ b/ash/system/chromeos/rotation/tray_rotation_lock_unittest.cc
|
| @@ -5,6 +5,7 @@
|
| #include "ash/system/chromeos/rotation/tray_rotation_lock.h"
|
|
|
| #include "ash/ash_switches.h"
|
| +#include "ash/content/display/screen_orientation_delegate_chromeos.h"
|
| #include "ash/display/display_manager.h"
|
| #include "ash/root_window_controller.h"
|
| #include "ash/shelf/shelf_widget.h"
|
| @@ -118,7 +119,7 @@ TEST_F(TrayRotationLockTest, CreateTrayViewDuringMaximizeModeAndRotationLock) {
|
| TearDownViews();
|
| Shell::GetInstance()->maximize_mode_controller()->
|
| EnableMaximizeModeWindowManager(true);
|
| - Shell::GetInstance()-> maximize_mode_controller()->SetRotationLocked(true);
|
| + Shell::GetInstance()->screen_orientation_delegate()->SetRotationLocked(true);
|
| SetUpForStatusAreaWidget(StatusAreaWidgetTestHelper::GetStatusAreaWidget());
|
| EXPECT_TRUE(tray_view()->visible());
|
| Shell::GetInstance()->maximize_mode_controller()->
|
| @@ -132,7 +133,7 @@ TEST_F(TrayRotationLockTest, TrayViewVisibilityChangesDuringMaximizeMode) {
|
| ASSERT_FALSE(tray_view()->visible());
|
| Shell::GetInstance()->maximize_mode_controller()->
|
| EnableMaximizeModeWindowManager(true);
|
| - Shell::GetInstance()->maximize_mode_controller()->SetRotationLocked(true);
|
| + Shell::GetInstance()->screen_orientation_delegate()->SetRotationLocked(true);
|
| EXPECT_TRUE(tray_view()->visible());
|
| Shell::GetInstance()->maximize_mode_controller()->
|
| EnableMaximizeModeWindowManager(false);
|
| @@ -204,19 +205,19 @@ TEST_F(TrayRotationLockTest, CreateSecondaryDefaultView) {
|
| TEST_F(TrayRotationLockTest, PerformActionOnDefaultView) {
|
| MaximizeModeController* maximize_mode_controller = Shell::GetInstance()->
|
| maximize_mode_controller();
|
| - ASSERT_FALSE(maximize_mode_controller->rotation_locked());
|
| - Shell::GetInstance()->maximize_mode_controller()->
|
| - EnableMaximizeModeWindowManager(true);
|
| + ScreenOrientationDelegate* screen_orientation_delegate =
|
| + Shell::GetInstance()->screen_orientation_delegate();
|
| + ASSERT_FALSE(screen_orientation_delegate->rotation_locked());
|
| + maximize_mode_controller->EnableMaximizeModeWindowManager(true);
|
| ASSERT_FALSE(tray_view()->visible());
|
|
|
| ui::GestureEvent tap(
|
| 0, 0, 0, base::TimeDelta(), ui::GestureEventDetails(ui::ET_GESTURE_TAP));
|
| default_view()->OnGestureEvent(&tap);
|
| - EXPECT_TRUE(maximize_mode_controller->rotation_locked());
|
| + EXPECT_TRUE(screen_orientation_delegate->rotation_locked());
|
| EXPECT_TRUE(tray_view()->visible());
|
|
|
| - Shell::GetInstance()->maximize_mode_controller()->
|
| - EnableMaximizeModeWindowManager(false);
|
| + maximize_mode_controller->EnableMaximizeModeWindowManager(false);
|
| }
|
|
|
| } // namespace ash
|
|
|