2011-06-10 Jer Noble <jer.noble@apple.com>
authorjer.noble@apple.com <jer.noble@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 11 Jun 2011 03:36:15 +0000 (03:36 +0000)
committerjer.noble@apple.com <jer.noble@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 11 Jun 2011 03:36:15 +0000 (03:36 +0000)
commit526120cdde142866ed28b673657f946a57a89645
tree123a540d2b907e1fb08a94296540dde34aa77ad1
parent24cba67a2ae4254d037d1d418978d6ea978643e6
2011-06-10  Jer Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler.

        REGRESSION: End of apple.com video in full-screen mode leads to unusable page.
        https://bugs.webkit.org/show_bug.cgi?id=62411

        * fullscreen/full-screen-remove-ancestor-after-expected.txt: Added.
        * fullscreen/full-screen-remove-ancestor-after.html: Added.
        * platform/mac/fullscreen/full-screen-remove-ancestor-after-expected.png: Added.
2011-06-09  Jer Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler.

        REGRESSION: End of apple.com video in full-screen mode leads to unusable page.
        https://bugs.webkit.org/show_bug.cgi?id=62411

        Test: fullscreen/full-screen-remove-ancestor-after.html

        The placeholder for RenderFullScreen was being created as a non-anonymous object, which led
        to the document's renderer being set to 0 when the placeholder was removed due to its parent
        being removed. Setting the placeholder to be anonymous, however, means that it will be
        coalesced with sibling anonymous blocks, so added the RenderFullScreenPlaceholder to the
        list of anonymous objects that are not considered anonymous blocks, to avoid the placeholder
        being so coalesced. To do so, made the placeholder object a true subclass, and add and
        override its destroy() function to notify the RenderFullScreen object that it has been
        destroyed.

        * rendering/RenderFullScreen.cpp:
        (RenderFullScreenPlaceholder::RenderFullScreenPlaceholder): Added.
        (RenderFullScreenPlaceholder::~RenderFullScreenPlaceholder): Added.
        (RenderFullScreenPlaceholder::isRenderFullScreenPlaceholder): Added.
        (RenderFullScreenPlaceholder::destroy): Notify the owner renderer that its placeholder
            has been destroyed.
        (RenderFullScreen::destroy): Assert that the m_placeholder ivar is 0 after destroying it.
        (RenderFullScreen::setPlaceholder): Added.
        (RenderFullScreen::createPlaceholder): Do not make the placeholder anonymous.
        * rendering/RenderFullScreen.h:
        * rendering/RenderObject.h:
        (WebCore::RenderObject::isRenderFullScreenPlaceholder): Added.
        (WebCore::RenderObject::isAnonymousBlock): Added the placeholder class to the list of
            objects which are not anonymous blocks.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@88591 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/fullscreen/full-screen-remove-ancestor-after-expected.txt [new file with mode: 0644]
LayoutTests/fullscreen/full-screen-remove-ancestor-after.html [new file with mode: 0644]
LayoutTests/platform/mac/fullscreen/full-screen-remove-ancestor-after-expected.png [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/dom/Document.cpp
Source/WebCore/rendering/RenderFullScreen.cpp
Source/WebCore/rendering/RenderFullScreen.h
Source/WebCore/rendering/RenderObject.h