diff options
author | scheib@chromium.org <scheib@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-03-28 18:30:35 +0000 |
---|---|---|
committer | scheib@chromium.org <scheib@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-03-28 18:30:35 +0000 |
commit | e83713478e414da7411b55849a3a2a2d64f04921 (patch) | |
tree | 0da126cddf6e2d87e051b277f78e2b33a5e16ea5 /chrome/browser/ui/fullscreen_controller.h | |
parent | 8200feed023ae96dd3250a5a2b1af7d0f1b68b93 (diff) | |
download | chromium_src-e83713478e414da7411b55849a3a2a2d64f04921.zip chromium_src-e83713478e414da7411b55849a3a2a2d64f04921.tar.gz chromium_src-e83713478e414da7411b55849a3a2a2d64f04921.tar.bz2 |
Automated tests for full screen & mouse lock M16 features
Tests added to browsertest to improve coverage for fullscreen and mouse lock transitions.
Several helper functions added to BrowserTest. Removes need to friend many tests and simplifies tests to increases readability.
IsFullscreenForTab() removed globally leaving only IsFullscreenForTabOrPending.
IsFullscreenForBrowser() added to fullscreen controller to enable testing.
typedef BrowserWithTestWindowTest BrowserTest; removed due to name conflict.
BUG=100678
TEST=
Review URL: http://codereview.chromium.org/9702055
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@129448 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/ui/fullscreen_controller.h')
-rw-r--r-- | chrome/browser/ui/fullscreen_controller.h | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/chrome/browser/ui/fullscreen_controller.h b/chrome/browser/ui/fullscreen_controller.h index e3bc446..9284c19 100644 --- a/chrome/browser/ui/fullscreen_controller.h +++ b/chrome/browser/ui/fullscreen_controller.h @@ -40,10 +40,21 @@ class FullscreenController : public base::RefCounted<FullscreenController> { virtual ~FullscreenController(); // Querying. - bool IsFullscreenForTab() const; - bool IsFullscreenForTab(const content::WebContents* tab) const; + + // Returns true if the window is currently fullscreen and was initially + // transitioned to fullscreen by a browser (vs tab) mode transition. + bool IsFullscreenForBrowser() const; + + // Returns true if fullscreen has been caused by a tab. + // The window may still be transitioning, and window_->IsFullscreen() + // may still return false. + bool IsFullscreenForTabOrPending() const; bool IsFullscreenForTabOrPending(const content::WebContents* tab) const; + // Returns true if the mouse has been locked or a lock request is pending + // user confirmation. + bool IsMouseLockedOrPending() const; + // Requests. void RequestToLockMouse(content::WebContents* tab); void ToggleFullscreenModeForTab(content::WebContents* tab, |