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

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

Issue 1159593006: Revert of Remove the allowfullscreen exemption for the video-specific fullscreen API (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rebase Created 5 years, 7 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.cpp » ('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 f66f59c4422ba466b0ee4f8c44bcdb3692db78c2..e78e631d106e9f765ceb364727108fa3e4fedde0 100644
--- a/Source/core/html/HTMLMediaElement.cpp
+++ b/Source/core/html/HTMLMediaElement.cpp
@@ -2782,7 +2782,7 @@ void HTMLMediaElement::mediaPlayerRequestFullscreen()
// user interaction or when it is technically required to play the video.
UserGestureIndicator gestureIndicator(DefinitelyProcessingNewUserGesture);
- Fullscreen::from(document()).requestFullscreen(*this, Fullscreen::InternalVideoRequest);
+ enterFullscreen();
}
void HTMLMediaElement::mediaPlayerRequestSeek(double time)
@@ -3140,6 +3140,20 @@ bool HTMLMediaElement::isFullscreen() const
return Fullscreen::isActiveFullScreenElement(*this);
}
+void HTMLMediaElement::enterFullscreen()
+{
+ WTF_LOG(Media, "HTMLMediaElement::enterFullscreen(%p)", this);
+
+ Fullscreen::from(document()).requestFullscreen(*this, Fullscreen::PrefixedVideoRequest);
+}
+
+void HTMLMediaElement::exitFullscreen()
+{
+ WTF_LOG(Media, "HTMLMediaElement::exitFullscreen(%p)", this);
+
+ Fullscreen::from(document()).exitFullscreen();
+}
+
void HTMLMediaElement::didBecomeFullscreenElement()
{
if (mediaControls())
« no previous file with comments | « Source/core/html/HTMLMediaElement.h ('k') | Source/core/html/HTMLVideoElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698