Chromium Code Reviews| Index: ash/content/display/screen_orientation_controller_chromeos_unittest.cc |
| diff --git a/ash/content/display/screen_orientation_controller_chromeos_unittest.cc b/ash/content/display/screen_orientation_controller_chromeos_unittest.cc |
| index 7874f01382a8c20060f5eb25b62e490c6e4b0406..5fd111c65b2016aab68fa7512fcbbeabb7840907 100644 |
| --- a/ash/content/display/screen_orientation_controller_chromeos_unittest.cc |
| +++ b/ash/content/display/screen_orientation_controller_chromeos_unittest.cc |
| @@ -7,6 +7,7 @@ |
| #include <memory> |
| #include <vector> |
| +#include "ash/aura/wm_window_aura.h" |
| #include "ash/common/ash_switches.h" |
| #include "ash/common/display/display_info.h" |
| #include "ash/common/wm/maximize_mode/maximize_mode_controller.h" |
| @@ -295,11 +296,15 @@ TEST_F(ScreenOrientationControllerTest, VisibilityChangesLock) { |
| delegate()->Lock(content.get(), blink::WebScreenOrientationLockLandscape); |
| EXPECT_TRUE(RotationLocked()); |
| - aura::Window* window = content->GetNativeView(); |
| + WmWindow* window = WmWindowAura::Get(content->GetNativeView()); |
| + ScreenOrientationController* controller = |
| + Shell::GetInstance()->screen_orientation_controller(); |
| window->Hide(); |
| + controller->OnWindowVisibilityChanging(window, false); |
|
jonross
2016/07/11 19:48:13
I'm a bit concerned that this is not being trigger
msw
2016/07/11 20:02:31
Might be async WmWindow behavior, or a plumbing is
jonross
2016/07/11 20:10:58
ScreenOrientationController should become a listen
msw
2016/07/11 21:53:10
Thanks for pushing me to dig in; I'll need to impl
|
| EXPECT_FALSE(RotationLocked()); |
| window->Show(); |
| + controller->OnWindowVisibilityChanging(window, true); |
| EXPECT_TRUE(RotationLocked()); |
| } |