| Index: chrome/browser/ui/fullscreen/fullscreen_controller.h
|
| diff --git a/chrome/browser/ui/fullscreen/fullscreen_controller.h b/chrome/browser/ui/fullscreen/fullscreen_controller.h
|
| index b7ff113c88f0af846a97e876e082fcc20bd59bb3..f36391c6ab579a290ae57f722a94ffb3db572f57 100644
|
| --- a/chrome/browser/ui/fullscreen/fullscreen_controller.h
|
| +++ b/chrome/browser/ui/fullscreen/fullscreen_controller.h
|
| @@ -22,14 +22,18 @@ class WebContents;
|
| }
|
|
|
| // There are two different kinds of fullscreen mode - "tab fullscreen" and
|
| -// "browser fullscreen". "Tab fullscreen" refers to when a tab enters
|
| -// fullscreen mode via the JS fullscreen API, and "browser fullscreen" refers
|
| -// to the user putting the browser itself into fullscreen mode from the UI. The
|
| -// difference is that tab fullscreen has implications for how the contents of
|
| -// the tab render (eg: a video element may grow to consume the whole tab),
|
| -// whereas browser fullscreen mode doesn't. Therefore if a user forces an exit
|
| -// from tab fullscreen, we need to notify the tab so it can stop rendering in
|
| -// its fullscreen mode.
|
| +// "browser fullscreen". "Tab fullscreen" refers to a renderer-initiated
|
| +// fullscreen mode (eg: from a Flash plugin or via the JS fullscreen API),
|
| +// whereas "browser fullscreen" refers to the user putting the browser itself
|
| +// into fullscreen mode from the UI. The difference is that tab fullscreen has
|
| +// implications for how the contents of the tab render (eg: a video element may
|
| +// grow to consume the whole tab), whereas browser fullscreen mode doesn't.
|
| +// Therefore if a user forces an exit from tab fullscreen, we need to notify the
|
| +// tab so it can stop rendering in its fullscreen mode.
|
| +//
|
| +// For Flash, FullscreenController will auto-accept all permission requests for
|
| +// fullscreen and/or mouse lock, since the assumption is that the plugin handles
|
| +// this for us.
|
|
|
| // This class implements fullscreen and mouselock behaviour.
|
| class FullscreenController : public content::NotificationObserver {
|
| @@ -45,7 +49,7 @@ class FullscreenController : public content::NotificationObserver {
|
|
|
| void ToggleFullscreenMode();
|
|
|
| - // Tab/HTML Fullscreen ///////////////////////////////////////////////////////
|
| + // Tab/HTML/Flash Fullscreen /////////////////////////////////////////////////
|
|
|
| // Returns true if fullscreen has been caused by a tab.
|
| // The window may still be transitioning, and window_->IsFullscreen()
|
| @@ -165,11 +169,14 @@ class FullscreenController : public content::NotificationObserver {
|
| ContentSetting GetFullscreenSetting(const GURL& url) const;
|
| ContentSetting GetMouseLockSetting(const GURL& url) const;
|
|
|
| + bool IsPrivilegedFullscreenForTab() const;
|
| + void UnlockMouse();
|
| +
|
| base::WeakPtrFactory<FullscreenController> ptr_factory_;
|
|
|
| - Browser* browser_;
|
| - BrowserWindow* window_;
|
| - Profile* profile_;
|
| + Browser* const browser_;
|
| + BrowserWindow* const window_;
|
| + Profile* const profile_;
|
|
|
| // If there is currently a tab in fullscreen mode (entered via
|
| // webkitRequestFullScreen), this is its WebContents.
|
|
|