Move continuation teardown from subclasses to RenderBoxModelObject.
authorakling@apple.com <akling@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 26 Oct 2014 20:20:31 +0000 (20:20 +0000)
committerakling@apple.com <akling@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 26 Oct 2014 20:20:31 +0000 (20:20 +0000)
commit687556524564eec2b51367c6c7aef0021f14d59d
tree1b219097dc69eec8e4af72f1c17cbcbbf424b206
parent4664e31cced601950f5ed71f18f6a50145b678bc
Move continuation teardown from subclasses to RenderBoxModelObject.
<https://webkit.org/b/138081>

Reviewed by Antti Koivisto.

Let RenderBoxModelObject::willBeDestroyed() tear down any continuation
instead of having every subclass do this themselves.

Also added a RenderElement bit tracking whether the renderer has a
continuation. This avoids a hash lookup every time we destroy a
RenderBoxModelObject that didn't have a continuation.

* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::willBeDestroyed):
* rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::willBeDestroyed):
* rendering/RenderBoxModelObject.cpp:
(WebCore::continuationMap):
(WebCore::RenderBoxModelObject::willBeDestroyed):
(WebCore::RenderBoxModelObject::continuation):
(WebCore::RenderBoxModelObject::setContinuation):
* rendering/RenderElement.cpp:
(WebCore::RenderElement::RenderElement):
* rendering/RenderElement.h:
(WebCore::RenderElement::setHasContinuation):
(WebCore::RenderElement::hasContinuation):
* rendering/RenderInline.cpp:
(WebCore::RenderInline::willBeDestroyed):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@175210 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/rendering/RenderBlock.cpp
Source/WebCore/rendering/RenderBlockFlow.cpp
Source/WebCore/rendering/RenderBoxModelObject.cpp
Source/WebCore/rendering/RenderElement.cpp
Source/WebCore/rendering/RenderElement.h
Source/WebCore/rendering/RenderInline.cpp