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

Unified Diff: Source/core/html/HTMLMediaElement.cpp

Issue 213193010: Restore the HTMLVideoElement-specific prefixed fullscreen API behind a flag (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: revive full-screen-iframe-legacy.html Created 6 years, 9 months 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
« no previous file with comments | « Source/core/html/HTMLMediaElement.h ('k') | Source/core/html/HTMLVideoElement.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/HTMLMediaElement.cpp
diff --git a/Source/core/html/HTMLMediaElement.cpp b/Source/core/html/HTMLMediaElement.cpp
index f5fb8f9311ddbe67a339b11b7c983bc1d9e04ec9..b027b138187af813fe690c5b5a2af81613f3c960 100644
--- a/Source/core/html/HTMLMediaElement.cpp
+++ b/Source/core/html/HTMLMediaElement.cpp
@@ -3189,6 +3189,14 @@ void HTMLMediaElement::enterFullscreen()
FullscreenElementStack::from(document()).requestFullScreenForElement(this, 0, FullscreenElementStack::ExemptIFrameAllowFullScreenRequirement);
}
+void HTMLMediaElement::exitFullscreen()
+{
+ WTF_LOG(Media, "HTMLMediaElement::exitFullscreen");
+
+ if (document().settings() && document().settings()->fullScreenEnabled() && isFullscreen())
+ FullscreenElementStack::from(document()).webkitCancelFullScreen();
+}
+
void HTMLMediaElement::didBecomeFullscreenElement()
{
if (hasMediaControls())
« no previous file with comments | « Source/core/html/HTMLMediaElement.h ('k') | Source/core/html/HTMLVideoElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698