Title: [87675] branches/safari-534-branch/Source/WebCore
Diff
Modified: branches/safari-534-branch/Source/WebCore/ChangeLog (87674 => 87675)
--- branches/safari-534-branch/Source/WebCore/ChangeLog 2011-05-30 06:22:06 UTC (rev 87674)
+++ branches/safari-534-branch/Source/WebCore/ChangeLog 2011-05-30 06:22:51 UTC (rev 87675)
@@ -1,5 +1,35 @@
2011-05-29 Mark Rowe <[email protected]>
+ Merge r87657.
+
+ 2011-05-29 Dan Bernstein <[email protected]>
+
+ Reviewed by Darin Adler.
+
+ <rdar://problem/9515650> 30 second rewind button obscured in fullscreen controller when video uses custom inline controls
+ https://bugs.webkit.org/show_bug.cgi?id=61714
+
+ * dom/Document.cpp:
+ (WebCore::Document::webkitDidEnterFullScreenForElement): Call didBecomeFullscreenElement() on the
+ new full screen element.
+ (WebCore::Document::webkitWillExitFullScreenForElement): Call willStopBeingFullscreenElement() on
+ the full screen element.
+ * dom/Element.h:
+ (WebCore::Element::didBecomeFullscreenElement): Added with a default implementation that does nothing.
+ (WebCore::Element::willStopBeingFullscreenElement): Ditto.
+ * html/HTMLMediaElement.cpp:
+ (WebCore::HTMLMediaElement::didBecomeFullscreenElement): Added this override, which calls
+ MediaControls::enteredFullscreen().
+ (WebCore::HTMLMediaElement::willStopBeingFullscreenElement): Added this override, which calls
+ MediaControls::exitedFullscreen().
+ * html/HTMLMediaElement.h:
+ * html/shadow/MediaControlElements.cpp:
+ (WebCore::MediaControlFullscreenButtonElement::preDispatchEventHandler): Removed calls to
+ enteredFullscreen() and exitedFullscreen() from here, since they are now called in response to
+ changes to the fullscreen-ness of the element.
+
+2011-05-29 Mark Rowe <[email protected]>
+
Merge r87643.
2011-05-29 Darin Adler <[email protected]>
Modified: branches/safari-534-branch/Source/WebCore/dom/Document.cpp (87674 => 87675)
--- branches/safari-534-branch/Source/WebCore/dom/Document.cpp 2011-05-30 06:22:06 UTC (rev 87674)
+++ branches/safari-534-branch/Source/WebCore/dom/Document.cpp 2011-05-30 06:22:51 UTC (rev 87675)
@@ -4899,7 +4899,7 @@
void Document::webkitDidEnterFullScreenForElement(Element*)
{
- ASSERT(m_fullScreenElement);
+ m_fullScreenElement->didBecomeFullscreenElement();
if (m_fullScreenRenderer) {
#if USE(ACCELERATED_COMPOSITING)
@@ -4918,6 +4918,8 @@
{
setContainsFullScreenElementRecursively(ownerElement(), false);
+ m_fullScreenElement->willStopBeingFullscreenElement();
+
if (m_fullScreenRenderer) {
setAnimatingFullScreen(true);
#if USE(ACCELERATED_COMPOSITING)
Modified: branches/safari-534-branch/Source/WebCore/dom/Element.h (87674 => 87675)
--- branches/safari-534-branch/Source/WebCore/dom/Element.h 2011-05-30 06:22:06 UTC (rev 87674)
+++ branches/safari-534-branch/Source/WebCore/dom/Element.h 2011-05-30 06:22:51 UTC (rev 87675)
@@ -279,6 +279,9 @@
// Use Document::registerForPrivateBrowsingStateChangedCallbacks() to subscribe to this.
virtual void privateBrowsingStateDidChange() { }
+ virtual void didBecomeFullscreenElement() { }
+ virtual void willStopBeingFullscreenElement() { }
+
bool isFinishedParsingChildren() const { return isParsingChildrenFinished(); }
virtual void finishParsingChildren();
virtual void beginParsingChildren();
Modified: branches/safari-534-branch/Source/WebCore/html/HTMLMediaElement.cpp (87674 => 87675)
--- branches/safari-534-branch/Source/WebCore/html/HTMLMediaElement.cpp 2011-05-30 06:22:06 UTC (rev 87674)
+++ branches/safari-534-branch/Source/WebCore/html/HTMLMediaElement.cpp 2011-05-30 06:22:51 UTC (rev 87675)
@@ -2622,6 +2622,18 @@
}
}
+void HTMLMediaElement::didBecomeFullscreenElement()
+{
+ if (hasMediaControls())
+ mediaControls()->enteredFullscreen();
+}
+
+void HTMLMediaElement::willStopBeingFullscreenElement()
+{
+ if (hasMediaControls())
+ mediaControls()->exitedFullscreen();
+}
+
PlatformMedia HTMLMediaElement::platformMedia() const
{
return m_player ? m_player->platformMedia() : NoPlatformMedia;
Modified: branches/safari-534-branch/Source/WebCore/html/HTMLMediaElement.h (87674 => 87675)
--- branches/safari-534-branch/Source/WebCore/html/HTMLMediaElement.h 2011-05-30 06:22:06 UTC (rev 87674)
+++ branches/safari-534-branch/Source/WebCore/html/HTMLMediaElement.h 2011-05-30 06:22:51 UTC (rev 87675)
@@ -229,7 +229,10 @@
virtual void recalcStyle(StyleChange);
virtual void defaultEventHandler(Event*);
-
+
+ virtual void didBecomeFullscreenElement();
+ virtual void willStopBeingFullscreenElement();
+
// ActiveDOMObject functions.
virtual bool canSuspend() const;
virtual void suspend(ReasonForSuspension);
Modified: branches/safari-534-branch/Source/WebCore/html/shadow/MediaControlElements.cpp (87674 => 87675)
--- branches/safari-534-branch/Source/WebCore/html/shadow/MediaControlElements.cpp 2011-05-30 06:22:06 UTC (rev 87674)
+++ branches/safari-534-branch/Source/WebCore/html/shadow/MediaControlElements.cpp 2011-05-30 06:22:51 UTC (rev 87675)
@@ -812,13 +812,10 @@
// video implementation without requiring them to implement their own full
// screen behavior.
if (document()->settings() && document()->settings()->fullScreenEnabled()) {
- if (document()->webkitIsFullScreen() && document()->webkitCurrentFullScreenElement() == mediaElement()) {
+ if (document()->webkitIsFullScreen() && document()->webkitCurrentFullScreenElement() == mediaElement())
document()->webkitCancelFullScreen();
- m_controls->exitedFullscreen();
- } else {
+ else
document()->requestFullScreenForElement(mediaElement(), 0, Document::ExemptIFrameAllowFulScreenRequirement);
- m_controls->enteredFullscreen();
- }
} else
#endif
mediaElement()->enterFullscreen();
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes