Index: Source/core/html/shadow/MediaControlElements.cpp |
diff --git a/Source/core/html/shadow/MediaControlElements.cpp b/Source/core/html/shadow/MediaControlElements.cpp |
index c5455e7c3d2dbedbe003bcd67d0cc97e03436059..3bec1c9f638747f1230b65f128a49036c57b2fb3 100644 |
--- a/Source/core/html/shadow/MediaControlElements.cpp |
+++ b/Source/core/html/shadow/MediaControlElements.cpp |
@@ -32,7 +32,6 @@ |
#include "bindings/v8/ExceptionStatePlaceholder.h" |
#include "core/dom/DOMTokenList.h" |
-#include "core/dom/FullscreenElementStack.h" |
#include "core/dom/shadow/ShadowRoot.h" |
#include "core/events/MouseEvent.h" |
#include "core/frame/LocalFrame.h" |
@@ -492,10 +491,10 @@ PassRefPtrWillBeRawPtr<MediaControlFullscreenButtonElement> MediaControlFullscre |
void MediaControlFullscreenButtonElement::defaultEventHandler(Event* event) |
{ |
if (event->type() == EventTypeNames::click) { |
- if (FullscreenElementStack::isActiveFullScreenElement(mediaElement())) |
- FullscreenElementStack::from(document()).webkitCancelFullScreen(); |
+ if (mediaElement().isFullscreen()) |
+ mediaElement().exitFullscreen(); |
else |
- FullscreenElementStack::from(document()).requestFullScreenForElement(mediaElement(), 0, FullscreenElementStack::ExemptIFrameAllowFullScreenRequirement); |
+ mediaElement().enterFullscreen(); |
event->setDefaultHandled(); |
} |
HTMLInputElement::defaultEventHandler(event); |