| Index: ash/content/screen_orientation_delegate_chromeos.cc
|
| diff --git a/ash/content/screen_orientation_delegate_chromeos.cc b/ash/content/screen_orientation_delegate_chromeos.cc
|
| index 68777e675d1649e20ad3f95d595104c4ac5f8a46..93bc8c6aca516519646cc159ae213f26e37893ac 100644
|
| --- a/ash/content/screen_orientation_delegate_chromeos.cc
|
| +++ b/ash/content/screen_orientation_delegate_chromeos.cc
|
| @@ -4,6 +4,7 @@
|
|
|
| #include "ash/content/screen_orientation_delegate_chromeos.h"
|
|
|
| +#include "ash/aura/wm_window_aura.h"
|
| #include "ash/display/screen_orientation_controller_chromeos.h"
|
| #include "ash/shell.h"
|
| #include "content/public/browser/screen_orientation_provider.h"
|
| @@ -14,6 +15,7 @@ namespace ash {
|
| ScreenOrientationDelegateChromeos::ScreenOrientationDelegateChromeos() {
|
| content::ScreenOrientationProvider::SetDelegate(this);
|
| }
|
| +
|
| ScreenOrientationDelegateChromeos::~ScreenOrientationDelegateChromeos() {
|
| content::ScreenOrientationProvider::SetDelegate(nullptr);
|
| }
|
| @@ -28,8 +30,8 @@ void ScreenOrientationDelegateChromeos::Lock(
|
| blink::WebScreenOrientationLockType lock_orientation) {
|
| Shell::GetInstance()
|
| ->screen_orientation_controller()
|
| - ->LockOrientationForWindow(web_contents->GetNativeView(),
|
| - lock_orientation);
|
| + ->LockOrientationForWindow(
|
| + WmWindowAura::Get(web_contents->GetNativeView()), lock_orientation);
|
| }
|
|
|
| bool ScreenOrientationDelegateChromeos::ScreenOrientationProviderSupported() {
|
| @@ -37,11 +39,13 @@ bool ScreenOrientationDelegateChromeos::ScreenOrientationProviderSupported() {
|
| ->screen_orientation_controller()
|
| ->ScreenOrientationProviderSupported();
|
| }
|
| +
|
| void ScreenOrientationDelegateChromeos::Unlock(
|
| content::WebContents* web_contents) {
|
| Shell::GetInstance()
|
| ->screen_orientation_controller()
|
| - ->UnlockOrientationForWindow(web_contents->GetNativeView());
|
| + ->UnlockOrientationForWindow(
|
| + WmWindowAura::Get(web_contents->GetNativeView()));
|
| }
|
|
|
| } // namespace ash
|
|
|