Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1221)

Unified Diff: chrome/browser/ui/fullscreen/fullscreen_controller.h

Issue 789533002: Fullscreen: make fullscreen requests come from RenderFrame (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
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 4b6934e796ea07aa5cf15ec4987a94393271d486..ac7bd217caa9b6c43180eb68c8468ce9332f37a5 100644
--- a/chrome/browser/ui/fullscreen/fullscreen_controller.h
+++ b/chrome/browser/ui/fullscreen/fullscreen_controller.h
@@ -95,6 +95,7 @@ class FullscreenController : public content::NotificationObserver {
// decide whether to also fullscreen the browser window. See
// 'FullscreenWithinTab Note'.
void ToggleFullscreenModeForTab(content::WebContents* web_contents,
+ const GURL& origin,
Charlie Reis 2014/12/10 00:51:21 nit: Document what |origin| means and is used for.
mlamouri (slow - plz ping) 2014/12/10 15:47:02 Done.
bool enter_fullscreen);
// Platform Fullscreen ///////////////////////////////////////////////////////
@@ -186,14 +187,14 @@ class FullscreenController : public content::NotificationObserver {
void ToggleFullscreenModeInternal(FullscreenInternalOption option);
void EnterFullscreenModeInternal(FullscreenInternalOption option);
void ExitFullscreenModeInternal();
- void SetFullscreenedTab(content::WebContents* tab);
+ void SetFullscreenedTab(content::WebContents* tab, const GURL& origin);
void SetMouseLockTab(content::WebContents* tab);
// Make the current tab exit fullscreen mode or mouse lock if it is in it.
void ExitTabFullscreenOrMouseLockIfNecessary();
void UpdateFullscreenExitBubbleContent();
- ContentSetting GetFullscreenSetting(const GURL& url) const;
+ ContentSetting GetFullscreenSetting() const;
ContentSetting GetMouseLockSetting(const GURL& url) const;
bool IsPrivilegedFullscreenForTab() const;
@@ -208,6 +209,10 @@ class FullscreenController : public content::NotificationObserver {
const;
void UnlockMouse();
+ // Helper methods that should be used in a TAB context.
+ GURL GetRequestingOrigin() const;
+ GURL GetEmbeddingOrigin() const;
+
Browser* const browser_;
BrowserWindow* const window_;
Profile* const profile_;
@@ -217,6 +222,11 @@ class FullscreenController : public content::NotificationObserver {
// Assign using SetFullscreenedTab().
content::WebContents* fullscreened_tab_;
+ // If a tab is fullscreen, the |fullscreen_origin_| should be used as the
+ // origin with regards to fullscreen. The |fullscreened_tab_| url should be
+ // used as the embedder url.
+ GURL fullscreened_origin_;
+
// The URL of the extension which trigerred "browser fullscreen" mode.
GURL extension_caused_fullscreen_;

Powered by Google App Engine
This is Rietveld 408576698