Title: [223072] trunk/Source/WebCore
- Revision
- 223072
- Author
- [email protected]
- Date
- 2017-10-09 14:57:52 -0700 (Mon, 09 Oct 2017)
Log Message
Remove redundant RenderObject::virtualContinuation
https://bugs.webkit.org/show_bug.cgi?id=178091
<rdar://problem/34892906>
Reviewed by Antti Koivisto.
virtualContinuation sounds like a feature of continuation, while it's just a (not super useful)helper override.
No change in functionality.
* rendering/RenderBlock.cpp:
(WebCore::canMergeContiguousAnonymousBlocks):
(WebCore::RenderBlock::takeChild):
* rendering/RenderBlock.h:
* rendering/RenderInline.h:
* rendering/RenderObject.h:
(WebCore::RenderObject::isBlockElementContinuation const):
(WebCore::RenderObject::virtualContinuation const): Deleted.
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (223071 => 223072)
--- trunk/Source/WebCore/ChangeLog 2017-10-09 21:49:01 UTC (rev 223071)
+++ trunk/Source/WebCore/ChangeLog 2017-10-09 21:57:52 UTC (rev 223072)
@@ -1,3 +1,24 @@
+2017-10-09 Zalan Bujtas <[email protected]>
+
+ Remove redundant RenderObject::virtualContinuation
+ https://bugs.webkit.org/show_bug.cgi?id=178091
+ <rdar://problem/34892906>
+
+ Reviewed by Antti Koivisto.
+
+ virtualContinuation sounds like a feature of continuation, while it's just a (not super useful)helper override.
+
+ No change in functionality.
+
+ * rendering/RenderBlock.cpp:
+ (WebCore::canMergeContiguousAnonymousBlocks):
+ (WebCore::RenderBlock::takeChild):
+ * rendering/RenderBlock.h:
+ * rendering/RenderInline.h:
+ * rendering/RenderObject.h:
+ (WebCore::RenderObject::isBlockElementContinuation const):
+ (WebCore::RenderObject::virtualContinuation const): Deleted.
+
2017-10-09 Dean Jackson <[email protected]>
[WebGL] Third IOSurface buffer might be allocated with the wrong size
Modified: trunk/Source/WebCore/rendering/RenderBlock.cpp (223071 => 223072)
--- trunk/Source/WebCore/rendering/RenderBlock.cpp 2017-10-09 21:49:01 UTC (rev 223071)
+++ trunk/Source/WebCore/rendering/RenderBlock.cpp 2017-10-09 21:57:52 UTC (rev 223072)
@@ -788,9 +788,14 @@
static bool canMergeContiguousAnonymousBlocks(RenderObject& oldChild, RenderObject* previous, RenderObject* next)
{
- if (oldChild.renderTreeBeingDestroyed() || oldChild.isInline() || oldChild.virtualContinuation())
+ ASSERT(!oldChild.renderTreeBeingDestroyed());
+
+ if (oldChild.isInline())
return false;
+ if (is<RenderBoxModelObject>(oldChild) && downcast<RenderBoxModelObject>(oldChild).continuation())
+ return false;
+
if (previous) {
if (!previous->isAnonymousBlock())
return false;
@@ -915,12 +920,11 @@
while (containingBlockIgnoringAnonymous && containingBlockIgnoringAnonymous->isAnonymousBlock())
containingBlockIgnoringAnonymous = containingBlockIgnoringAnonymous->containingBlock();
for (RenderObject* current = this; current; current = current->previousInPreOrder(containingBlockIgnoringAnonymous)) {
- if (current->virtualContinuation() != this)
+ if (!is<RenderBoxModelObject>(current) || downcast<RenderBoxModelObject>(*current).continuation() != this)
continue;
-
// Found our previous continuation. We just need to point it to
// |this|'s next continuation.
- RenderBoxModelObject* nextContinuation = continuation();
+ auto* nextContinuation = continuation();
if (is<RenderInline>(*current))
downcast<RenderInline>(*current).setContinuation(nextContinuation);
else if (is<RenderBlock>(*current))
@@ -927,7 +931,6 @@
downcast<RenderBlock>(*current).setContinuation(nextContinuation);
else
ASSERT_NOT_REACHED();
-
break;
}
setContinuation(nullptr);
Modified: trunk/Source/WebCore/rendering/RenderBlock.h (223071 => 223072)
--- trunk/Source/WebCore/rendering/RenderBlock.h 2017-10-09 21:49:01 UTC (rev 223071)
+++ trunk/Source/WebCore/rendering/RenderBlock.h 2017-10-09 21:57:52 UTC (rev 223072)
@@ -188,7 +188,6 @@
void addContinuationWithOutline(RenderInline*);
bool paintsContinuationOutline(RenderInline*);
- RenderBoxModelObject* virtualContinuation() const final { return continuation(); }
bool isAnonymousBlockContinuation() const { return isAnonymousBlock() && continuation(); }
WEBCORE_EXPORT RenderInline* inlineElementContinuation() const;
RenderBlock* blockElementContinuation() const;
Modified: trunk/Source/WebCore/rendering/RenderInline.h (223071 => 223072)
--- trunk/Source/WebCore/rendering/RenderInline.h 2017-10-09 21:49:01 UTC (rev 223071)
+++ trunk/Source/WebCore/rendering/RenderInline.h 2017-10-09 21:57:52 UTC (rev 223072)
@@ -78,7 +78,6 @@
void absoluteQuadsForSelection(Vector<FloatQuad>& quads) const override;
#endif
- RenderBoxModelObject* virtualContinuation() const final { return continuation(); }
RenderInline* inlineElementContinuation() const;
void updateDragState(bool dragOn) final;
Modified: trunk/Source/WebCore/rendering/RenderObject.h (223071 => 223072)
--- trunk/Source/WebCore/rendering/RenderObject.h 2017-10-09 21:49:01 UTC (rev 223071)
+++ trunk/Source/WebCore/rendering/RenderObject.h 2017-10-09 21:57:52 UTC (rev 223072)
@@ -414,7 +414,6 @@
bool isElementContinuation() const { return node() && node()->renderer() != this; }
bool isInlineElementContinuation() const { return isElementContinuation() && isInline(); }
bool isBlockElementContinuation() const { return isElementContinuation() && !isInline(); }
- virtual RenderBoxModelObject* virtualContinuation() const { return nullptr; }
bool isFloating() const { return m_bitfields.floating(); }
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes