Index: third_party/WebKit/Source/core/html/HTMLMediaElement.cpp |
diff --git a/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp b/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp |
index 7a3c5bb811ac9c53744959f8ea10062c0685cee2..9f41e2b5b6e7f6ec88fa14b27fde711e54343686 100644 |
--- a/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp |
+++ b/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp |
@@ -3104,8 +3104,11 @@ void HTMLMediaElement::didBecomeFullscreenElement() |
mediaControls()->enteredFullscreen(); |
// Cache this in case the player is destroyed before leaving fullscreen. |
m_inOverlayFullscreenVideo = usesOverlayFullscreenVideo(); |
- if (m_inOverlayFullscreenVideo) |
+ if (m_inOverlayFullscreenVideo) { |
document().layoutView()->compositor()->setNeedsCompositingUpdate(CompositingUpdateRebuildTree); |
+ } else if (webMediaPlayer()) { |
+ webMediaPlayer()->enterFullscreen(); |
+ } |
} |
void HTMLMediaElement::willStopBeingFullscreenElement() |
@@ -3115,6 +3118,8 @@ void HTMLMediaElement::willStopBeingFullscreenElement() |
if (m_inOverlayFullscreenVideo) |
document().layoutView()->compositor()->setNeedsCompositingUpdate(CompositingUpdateRebuildTree); |
m_inOverlayFullscreenVideo = false; |
+ if (webMediaPlayer()) |
+ webMediaPlayer()->exitedFullscreen(); |
} |
WebLayer* HTMLMediaElement::platformLayer() const |