Changeset 224933 in webkit
- Timestamp:
- Nov 16, 2017 12:26:37 PM (6 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 16 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r224929 r224933 1 2017-11-16 Zalan Bujtas <zalan@apple.com> 2 3 Always invoke RenderObject::insertedIntoTree/willBeRemovedFromTree 4 https://bugs.webkit.org/show_bug.cgi?id=178007 5 6 Reviewed by Antti Koivisto. 7 8 Based on Antti Koivisto's patch: 9 These call are currently skipped in some cases making them bug prone and difficult to reason about. 10 This is done as an optimization that doesn't appear to be valuable anymore. 11 12 Covered by existing tests. 13 14 * rendering/RenderBlock.cpp: 15 (WebCore::RenderBlock::makeChildrenNonInline): 16 (WebCore::RenderBlock::dropAnonymousBoxChild): 17 (WebCore::RenderBlock::takeChild): 18 * rendering/RenderBlock.h: 19 (WebCore::RenderBlock::moveAllChildrenIncludingFloatsTo): 20 * rendering/RenderBlockFlow.cpp: 21 (WebCore::RenderBlockFlow::styleDidChange): 22 (WebCore::RenderBlockFlow::moveAllChildrenIncludingFloatsTo): 23 * rendering/RenderBlockFlow.h: 24 * rendering/RenderBox.cpp: 25 (WebCore::RenderBox::splitAnonymousBoxesAroundChild): 26 * rendering/RenderBoxModelObject.cpp: 27 (WebCore::RenderBoxModelObject::moveChildTo): 28 (WebCore::RenderBoxModelObject::moveChildrenTo): 29 * rendering/RenderBoxModelObject.h: 30 (WebCore::RenderBoxModelObject::moveChildTo): 31 (WebCore::RenderBoxModelObject::moveAllChildrenTo): 32 (WebCore::RenderBoxModelObject::moveChildrenTo): 33 * rendering/RenderElement.cpp: 34 (WebCore::RenderElement::addChild): 35 (WebCore::RenderElement::takeChild): 36 (WebCore::RenderElement::insertChildInternal): 37 (WebCore::RenderElement::takeChildInternal): 38 (WebCore::RenderElement::handleDynamicFloatPositionChange): 39 * rendering/RenderElement.h: 40 * rendering/RenderInline.cpp: 41 (WebCore::RenderInline::splitInlines): 42 (WebCore::RenderInline::splitFlow): 43 (WebCore::RenderInline::childBecameNonInline): 44 * rendering/RenderMultiColumnFlow.cpp: 45 (WebCore::RenderMultiColumnFlow::fragmentedFlowDescendantInserted): 46 * rendering/RenderRubyBase.cpp: 47 (WebCore::RenderRubyBase::moveInlineChildren): 48 (WebCore::RenderRubyBase::moveBlockChildren): 49 * rendering/RenderRubyRun.cpp: 50 (WebCore::RenderRubyRun::takeChild): 51 * rendering/RenderTableRow.cpp: 52 (WebCore::RenderTableRow::collapseAndDestroyAnonymousSiblingRows): 53 * style/RenderTreeUpdaterMultiColumn.cpp: 54 (WebCore::RenderTreeUpdater::MultiColumn::createFragmentedFlow): 55 (WebCore::RenderTreeUpdater::MultiColumn::destroyFragmentedFlow): 56 1 57 2017-11-14 Dean Jackson <dino@apple.com> 2 58 -
trunk/Source/WebCore/rendering/RenderBlock.cpp
r224600 r224933 705 705 auto newBlock = createAnonymousBlock(); 706 706 auto& block = *newBlock; 707 insertChildInternal(WTFMove(newBlock), inlineRunStart , NotifyChildren);708 moveChildrenTo(&block, inlineRunStart, child );707 insertChildInternal(WTFMove(newBlock), inlineRunStart); 708 moveChildrenTo(&block, inlineRunStart, child, RenderBoxModelObject::NormalizeAfterInsertion::No); 709 709 } 710 710 … … 811 811 RenderObject* nextSibling = child.nextSibling(); 812 812 813 auto toBeDeleted = takeChildInternal(child , child.hasLayer() ? NotifyChildren : DontNotifyChildren);814 child.moveAllChildrenTo(this, nextSibling, child.hasLayer());813 auto toBeDeleted = takeChildInternal(child); 814 child.moveAllChildrenTo(this, nextSibling, RenderBoxModelObject::NormalizeAfterInsertion::No); 815 815 // Delete the now-empty block's lines and nuke it. 816 816 child.deleteLines(); … … 844 844 ASSERT(!inlineChildrenBlock.continuation()); 845 845 // Cache this value as it might get changed in setStyle() call. 846 bool inlineChildrenBlockHasLayer = inlineChildrenBlock.hasLayer();847 846 inlineChildrenBlock.setStyle(RenderStyle::createAnonymousStyleWithDisplay(style(), BLOCK)); 848 auto blockToMove = takeChildInternal(inlineChildrenBlock , inlineChildrenBlockHasLayer ? NotifyChildren : DontNotifyChildren);847 auto blockToMove = takeChildInternal(inlineChildrenBlock); 849 848 850 849 // Now just put the inlineChildrenBlock inside the blockChildrenBlock. 851 850 RenderObject* beforeChild = prev == &inlineChildrenBlock ? blockChildrenBlock.firstChild() : nullptr; 852 blockChildrenBlock.insertChildInternal(WTFMove(blockToMove), beforeChild, 853 (inlineChildrenBlockHasLayer || blockChildrenBlock.hasLayer()) ? NotifyChildren : DontNotifyChildren); 851 blockChildrenBlock.insertChildInternal(WTFMove(blockToMove), beforeChild); 854 852 next->setNeedsLayoutAndPrefWidthsRecalc(); 855 853 … … 863 861 // Take all the children out of the |next| block and put them in 864 862 // the |prev| block. 865 nextBlock.moveAllChildrenIncludingFloatsTo(prevBlock, nextBlock.hasLayer() || prevBlock.hasLayer());863 nextBlock.moveAllChildrenIncludingFloatsTo(prevBlock, RenderBoxModelObject::NormalizeAfterInsertion::No); 866 864 867 865 // Delete the now-empty block's lines and nuke it. -
trunk/Source/WebCore/rendering/RenderBlock.h
r224600 r224933 439 439 440 440 // FIXME-BLOCKFLOW: Remove virtualizaion when all callers have moved to RenderBlockFlow 441 virtual void moveAllChildrenIncludingFloatsTo(RenderBlock& toBlock, bool fullRemoveInsert) { moveAllChildrenTo(&toBlock, fullRemoveInsert); }441 virtual void moveAllChildrenIncludingFloatsTo(RenderBlock& toBlock, RenderBoxModelObject::NormalizeAfterInsertion normalizeAfterInsertion) { moveAllChildrenTo(&toBlock, normalizeAfterInsertion); } 442 442 443 443 void addChildToContinuation(RenderPtr<RenderObject> newChild, RenderObject* beforeChild); -
trunk/Source/WebCore/rendering/RenderBlockFlow.cpp
r224653 r224933 2027 2027 // It copies the logic of RenderBlock::addChildIgnoringContinuation 2028 2028 if (noLongerAffectsParentBlock() && style().isFloating() && previousSibling() && previousSibling()->isAnonymousBlock()) 2029 downcast<RenderBoxModelObject>(*parent()).moveChildTo(&downcast<RenderBoxModelObject>(*previousSibling()), this );2029 downcast<RenderBoxModelObject>(*parent()).moveChildTo(&downcast<RenderBoxModelObject>(*previousSibling()), this, RenderBoxModelObject::NormalizeAfterInsertion::No); 2030 2030 2031 2031 if (diff >= StyleDifferenceRepaint) { … … 2109 2109 } 2110 2110 2111 void RenderBlockFlow::moveAllChildrenIncludingFloatsTo(RenderBlock& toBlock, bool fullRemoveInsert)2111 void RenderBlockFlow::moveAllChildrenIncludingFloatsTo(RenderBlock& toBlock, RenderBoxModelObject::NormalizeAfterInsertion normalizeAfterInsertion) 2112 2112 { 2113 2113 auto& toBlockFlow = downcast<RenderBlockFlow>(toBlock); 2114 moveAllChildrenTo(&toBlockFlow, fullRemoveInsert);2114 moveAllChildrenTo(&toBlockFlow, normalizeAfterInsertion); 2115 2115 addFloatsToNewParent(toBlockFlow); 2116 2116 } -
trunk/Source/WebCore/rendering/RenderBlockFlow.h
r224653 r224933 476 476 void paintFloats(PaintInfo&, const LayoutPoint&, bool preservePhase = false) override; 477 477 478 void moveAllChildrenIncludingFloatsTo(RenderBlock& toBlock, bool fullRemoveInsert) override;478 void moveAllChildrenIncludingFloatsTo(RenderBlock& toBlock, RenderBoxModelObject::NormalizeAfterInsertion) override; 479 479 void repaintOverhangingFloats(bool paintAllDescendants) final; 480 480 void clipOutFloatingObjects(RenderBlock&, const PaintInfo*, const LayoutPoint&, const LayoutSize&) override; -
trunk/Source/WebCore/rendering/RenderBox.cpp
r224579 r224933 4938 4938 // See for example RenderTableCell:clippedOverflowRectForRepaint. 4939 4939 markBoxForRelayoutAfterSplit(*parentBox); 4940 parentBox->insertChildInternal(WTFMove(newPostBox), boxToSplit.nextSibling() , NotifyChildren);4941 boxToSplit.moveChildrenTo(&postBox, beforeChild, nullptr, true);4940 parentBox->insertChildInternal(WTFMove(newPostBox), boxToSplit.nextSibling()); 4941 boxToSplit.moveChildrenTo(&postBox, beforeChild, nullptr, RenderBoxModelObject::NormalizeAfterInsertion::Yes); 4942 4942 4943 4943 markBoxForRelayoutAfterSplit(boxToSplit); -
trunk/Source/WebCore/rendering/RenderBoxModelObject.cpp
r224600 r224933 2680 2680 } 2681 2681 2682 void RenderBoxModelObject::moveChildTo(RenderBoxModelObject* toBoxModelObject, RenderObject* child, RenderObject* beforeChild, bool fullRemoveInsert)2683 { 2684 // We assume that callers have cleared their positioned objects list for child moves (!fullRemoveInsert)so the2682 void RenderBoxModelObject::moveChildTo(RenderBoxModelObject* toBoxModelObject, RenderObject* child, RenderObject* beforeChild, NormalizeAfterInsertion normalizeAfterInsertion) 2683 { 2684 // We assume that callers have cleared their positioned objects list for child moves so the 2685 2685 // positioned renderer maps don't become stale. It would be too slow to do the map lookup on each call. 2686 ASSERT( !fullRemoveInsert|| !is<RenderBlock>(*this) || !downcast<RenderBlock>(*this).hasPositionedObjects());2686 ASSERT(normalizeAfterInsertion == NormalizeAfterInsertion::No || !is<RenderBlock>(*this) || !downcast<RenderBlock>(*this).hasPositionedObjects()); 2687 2687 2688 2688 ASSERT(this == child->parent()); 2689 2689 ASSERT(!beforeChild || toBoxModelObject == beforeChild->parent()); 2690 if ( fullRemoveInsert&& (toBoxModelObject->isRenderBlock() || toBoxModelObject->isRenderInline())) {2690 if (normalizeAfterInsertion == NormalizeAfterInsertion::Yes && (toBoxModelObject->isRenderBlock() || toBoxModelObject->isRenderInline())) { 2691 2691 // Takes care of adding the new child correctly if toBlock and fromBlock 2692 2692 // have different kind of children (block vs inline). 2693 auto childToMove = takeChildInternal(*child , NotifyChildren);2693 auto childToMove = takeChildInternal(*child); 2694 2694 toBoxModelObject->addChild(WTFMove(childToMove), beforeChild); 2695 2695 } else { 2696 NotifyChildrenType notifyType = fullRemoveInsert ? NotifyChildren : DontNotifyChildren; 2697 auto childToMove = takeChildInternal(*child, notifyType); 2698 toBoxModelObject->insertChildInternal(WTFMove(childToMove), beforeChild, notifyType); 2699 } 2700 } 2701 2702 void RenderBoxModelObject::moveChildrenTo(RenderBoxModelObject* toBoxModelObject, RenderObject* startChild, RenderObject* endChild, RenderObject* beforeChild, bool fullRemoveInsert) 2696 auto childToMove = takeChildInternal(*child); 2697 toBoxModelObject->insertChildInternal(WTFMove(childToMove), beforeChild); 2698 } 2699 } 2700 2701 void RenderBoxModelObject::moveChildrenTo(RenderBoxModelObject* toBoxModelObject, RenderObject* startChild, RenderObject* endChild, RenderObject* beforeChild, NormalizeAfterInsertion normalizeAfterInsertion) 2703 2702 { 2704 2703 // This condition is rarely hit since this function is usually called on 2705 2704 // anonymous blocks which can no longer carry positioned objects (see r120761) 2706 2705 // or when fullRemoveInsert is false. 2707 if ( fullRemoveInsert&& is<RenderBlock>(*this)) {2706 if (normalizeAfterInsertion == NormalizeAfterInsertion::Yes && is<RenderBlock>(*this)) { 2708 2707 downcast<RenderBlock>(*this).removePositionedObjects(nullptr); 2709 2708 if (is<RenderBlockFlow>(*this)) … … 2733 2732 } 2734 2733 2735 moveChildTo(toBoxModelObject, child, beforeChild, fullRemoveInsert);2734 moveChildTo(toBoxModelObject, child, beforeChild, normalizeAfterInsertion); 2736 2735 child = nextSibling; 2737 2736 } -
trunk/Source/WebCore/rendering/RenderBoxModelObject.h
r224600 r224933 278 278 void clearFirstLetterRemainingText(); 279 279 280 // These functions are only used internally to manipulate the render tree structure via remove/insert/appendChildNode.281 // Since they are typically called only to move objects around within anonymous blocks, the default for fullRemoveInsert is false rather than true.282 void moveChildTo(RenderBoxModelObject* toBoxModelObject, RenderObject* child, RenderObject* beforeChild, bool fullRemoveInsert = false);283 void moveChildTo(RenderBoxModelObject* toBoxModelObject, RenderObject* child, bool fullRemoveInsert = false)284 { 285 moveChildTo(toBoxModelObject, child, nullptr, fullRemoveInsert);286 } 287 void moveAllChildrenTo(RenderBoxModelObject* toBoxModelObject, bool fullRemoveInsert = false)288 { 289 moveAllChildrenTo(toBoxModelObject, nullptr, fullRemoveInsert);290 } 291 void moveAllChildrenTo(RenderBoxModelObject* toBoxModelObject, RenderObject* beforeChild, bool fullRemoveInsert = false)292 { 293 moveChildrenTo(toBoxModelObject, firstChild(), nullptr, beforeChild, fullRemoveInsert);280 // NormalizeAfterInsertion::Yes ensures that the destination subtree is consistent after the insertion (anonymous wrappers etc). 281 enum class NormalizeAfterInsertion { No, Yes }; 282 void moveChildTo(RenderBoxModelObject* toBoxModelObject, RenderObject* child, RenderObject* beforeChild, NormalizeAfterInsertion); 283 void moveChildTo(RenderBoxModelObject* toBoxModelObject, RenderObject* child, NormalizeAfterInsertion normalizeAfterInsertion) 284 { 285 moveChildTo(toBoxModelObject, child, nullptr, normalizeAfterInsertion); 286 } 287 void moveAllChildrenTo(RenderBoxModelObject* toBoxModelObject, NormalizeAfterInsertion normalizeAfterInsertion) 288 { 289 moveAllChildrenTo(toBoxModelObject, nullptr, normalizeAfterInsertion); 290 } 291 void moveAllChildrenTo(RenderBoxModelObject* toBoxModelObject, RenderObject* beforeChild, NormalizeAfterInsertion normalizeAfterInsertion) 292 { 293 moveChildrenTo(toBoxModelObject, firstChild(), nullptr, beforeChild, normalizeAfterInsertion); 294 294 } 295 295 // Move all of the kids from |startChild| up to but excluding |endChild|. 0 can be passed as the |endChild| to denote 296 296 // that all the kids from |startChild| onwards should be moved. 297 void moveChildrenTo(RenderBoxModelObject* toBoxModelObject, RenderObject* startChild, RenderObject* endChild, bool fullRemoveInsert = false)298 { 299 moveChildrenTo(toBoxModelObject, startChild, endChild, nullptr, fullRemoveInsert);300 } 301 void moveChildrenTo(RenderBoxModelObject* toBoxModelObject, RenderObject* startChild, RenderObject* endChild, RenderObject* beforeChild, bool fullRemoveInsert = false);297 void moveChildrenTo(RenderBoxModelObject* toBoxModelObject, RenderObject* startChild, RenderObject* endChild, NormalizeAfterInsertion normalizeAfterInsertion) 298 { 299 moveChildrenTo(toBoxModelObject, startChild, endChild, nullptr, normalizeAfterInsertion); 300 } 301 void moveChildrenTo(RenderBoxModelObject* toBoxModelObject, RenderObject* startChild, RenderObject* endChild, RenderObject* beforeChild, NormalizeAfterInsertion); 302 302 303 303 enum ScaleByEffectiveZoomOrNot { ScaleByEffectiveZoom, DoNotScaleByEffectiveZoom }; -
trunk/Source/WebCore/rendering/RenderElement.cpp
r224563 r224933 492 492 table->addChild(WTFMove(newChild)); 493 493 } else 494 insertChildInternal(WTFMove(newChild), beforeChild , NotifyChildren);494 insertChildInternal(WTFMove(newChild), beforeChild); 495 495 496 496 if (is<RenderText>(child)) … … 513 513 RenderPtr<RenderObject> RenderElement::takeChild(RenderObject& oldChild) 514 514 { 515 return takeChildInternal(oldChild , NotifyChildren);515 return takeChildInternal(oldChild); 516 516 } 517 517 … … 530 530 } 531 531 532 void RenderElement::insertChildInternal(RenderPtr<RenderObject> newChildPtr, RenderObject* beforeChild , NotifyChildrenType notifyChildren)532 void RenderElement::insertChildInternal(RenderPtr<RenderObject> newChildPtr, RenderObject* beforeChild) 533 533 { 534 534 RELEASE_ASSERT_WITH_MESSAGE(!view().frameView().layoutContext().layoutState(), "Layout must not mutate render tree"); … … 568 568 newChild->initializeFragmentedFlowStateOnInsertion(); 569 569 if (!renderTreeBeingDestroyed()) { 570 if (notifyChildren == NotifyChildren) 571 newChild->insertedIntoTree(); 570 newChild->insertedIntoTree(); 572 571 if (is<RenderElement>(*newChild)) 573 572 RenderCounter::rendererSubtreeAttached(downcast<RenderElement>(*newChild)); … … 587 586 } 588 587 589 RenderPtr<RenderObject> RenderElement::takeChildInternal(RenderObject& oldChild , NotifyChildrenType notifyChildren)588 RenderPtr<RenderObject> RenderElement::takeChildInternal(RenderObject& oldChild) 590 589 { 591 590 RELEASE_ASSERT_WITH_MESSAGE(!view().frameView().layoutContext().layoutState(), "Layout must not mutate render tree"); … … 600 599 // that a positioned child got yanked). We also repaint, so that the area exposed when the child 601 600 // disappears gets repainted properly. 602 if (!renderTreeBeingDestroyed() && notifyChildren == NotifyChildren &&oldChild.everHadLayout()) {601 if (!renderTreeBeingDestroyed() && oldChild.everHadLayout()) { 603 602 oldChild.setNeedsLayoutAndPrefWidthsRecalc(); 604 603 // We only repaint |oldChild| if we have a RenderLayer as its visual overflow may not be tracked by its parent. … … 623 622 frame().selection().setNeedsSelectionUpdate(); 624 623 625 if (!renderTreeBeingDestroyed() && notifyChildren == NotifyChildren)624 if (!renderTreeBeingDestroyed()) 626 625 oldChild.willBeRemovedFromTree(); 627 626 … … 958 957 auto newBlock = downcast<RenderBlock>(*parent()).createAnonymousBlock(); 959 958 auto& block = *newBlock; 960 parent()->insertChildInternal(WTFMove(newBlock), this , RenderElement::NotifyChildren);961 auto thisToMove = parent()->takeChildInternal(*this , RenderElement::NotifyChildren);962 block.insertChildInternal(WTFMove(thisToMove), nullptr , RenderElement::NotifyChildren);959 parent()->insertChildInternal(WTFMove(newBlock), this); 960 auto thisToMove = parent()->takeChildInternal(*this); 961 block.insertChildInternal(WTFMove(thisToMove), nullptr); 963 962 } 964 963 } -
trunk/Source/WebCore/rendering/RenderElement.h
r224583 r224933 100 100 RenderLayer* findNextLayer(RenderLayer* parentLayer, RenderObject* startPoint, bool checkParent = true); 101 101 102 enum NotifyChildrenType { NotifyChildren, DontNotifyChildren }; 103 void insertChildInternal(RenderPtr<RenderObject>, RenderObject* beforeChild, NotifyChildrenType); 104 RenderPtr<RenderObject> takeChildInternal(RenderObject&, NotifyChildrenType) WARN_UNUSED_RETURN; 102 void insertChildInternal(RenderPtr<RenderObject>, RenderObject* beforeChild); 103 RenderPtr<RenderObject> takeChildInternal(RenderObject&) WARN_UNUSED_RETURN; 105 104 106 105 virtual RenderElement* hoverAncestor() const; -
trunk/Source/WebCore/rendering/RenderInline.cpp
r224600 r224933 403 403 // every time, which is a bit wasteful. 404 404 } 405 auto childToMove = rendererToMove->parent()->takeChildInternal(*rendererToMove , NotifyChildren);405 auto childToMove = rendererToMove->parent()->takeChildInternal(*rendererToMove); 406 406 cloneInline->addChildIgnoringContinuation(WTFMove(childToMove)); 407 407 rendererToMove->setNeedsLayoutAndPrefWidthsRecalc(); … … 441 441 for (auto* sibling = currentChild->nextSibling(); sibling;) { 442 442 auto* next = sibling->nextSibling(); 443 auto childToMove = current->takeChildInternal(*sibling , NotifyChildren);443 auto childToMove = current->takeChildInternal(*sibling); 444 444 cloneInline->addChildIgnoringContinuation(WTFMove(childToMove)); 445 445 sibling->setNeedsLayoutAndPrefWidthsRecalc(); … … 459 459 460 460 // Now we are at the block level. We need to put the clone into the toBlock. 461 toBlock->insertChildInternal(WTFMove(cloneInline), nullptr , NotifyChildren);461 toBlock->insertChildInternal(WTFMove(cloneInline), nullptr); 462 462 463 463 // Now take all the children after currentChild and remove them from the fromBlock … … 465 465 for (auto* current = currentChild->nextSibling(); current;) { 466 466 auto* next = current->nextSibling(); 467 auto childToMove = fromBlock->takeChildInternal(*current , NotifyChildren);468 toBlock->insertChildInternal(WTFMove(childToMove), nullptr , NotifyChildren);467 auto childToMove = fromBlock->takeChildInternal(*current); 468 toBlock->insertChildInternal(WTFMove(childToMove), nullptr); 469 469 current = next; 470 470 } … … 504 504 RenderObject* boxFirst = madeNewBeforeBlock ? block->firstChild() : pre->nextSibling(); 505 505 if (createdPre) 506 block->insertChildInternal(WTFMove(createdPre), boxFirst , NotifyChildren);507 block->insertChildInternal(WTFMove(newBlockBox), boxFirst , NotifyChildren);508 block->insertChildInternal(WTFMove(createdPost), boxFirst , NotifyChildren);506 block->insertChildInternal(WTFMove(createdPre), boxFirst); 507 block->insertChildInternal(WTFMove(newBlockBox), boxFirst); 508 block->insertChildInternal(WTFMove(createdPost), boxFirst); 509 509 block->setChildrenInline(false); 510 510 … … 514 514 RenderObject* no = o; 515 515 o = no->nextSibling(); 516 auto childToMove = block->takeChildInternal(*no , NotifyChildren);517 pre->insertChildInternal(WTFMove(childToMove), nullptr , NotifyChildren);516 auto childToMove = block->takeChildInternal(*no); 517 pre->insertChildInternal(WTFMove(childToMove), nullptr); 518 518 no->setNeedsLayoutAndPrefWidthsRecalc(); 519 519 } … … 1372 1372 newBox->insertIntoContinuationChainAfter(*this); 1373 1373 RenderObject* beforeChild = child.nextSibling(); 1374 auto removedChild = takeChildInternal(child , NotifyChildren);1374 auto removedChild = takeChildInternal(child); 1375 1375 splitFlow(beforeChild, WTFMove(newBox), WTFMove(removedChild), oldContinuation); 1376 1376 } -
trunk/Source/WebCore/rendering/RenderMultiColumnFlow.cpp
r224616 r224933 369 369 gShiftingSpanner = true; 370 370 RenderBlockFlow& ancestorBlock = downcast<RenderBlockFlow>(*spanner->parent()); 371 ancestorBlock.moveChildTo(placeholder.parentBox(), spanner, placeholder.nextSibling(), true);371 ancestorBlock.moveChildTo(placeholder.parentBox(), spanner, placeholder.nextSibling(), RenderBoxModelObject::NormalizeAfterInsertion::Yes); 372 372 gShiftingSpanner = false; 373 373 -
trunk/Source/WebCore/rendering/RenderRubyBase.cpp
r224537 r224933 100 100 auto newToBlock = toBase->createAnonymousBlock(); 101 101 toBlock = newToBlock.get(); 102 toBase->insertChildInternal(WTFMove(newToBlock), nullptr , NotifyChildren);102 toBase->insertChildInternal(WTFMove(newToBlock), nullptr); 103 103 } 104 104 } 105 105 // Move our inline children into the target block we determined above. 106 moveChildrenTo(toBlock, firstChild(), beforeChild );106 moveChildrenTo(toBlock, firstChild(), beforeChild, RenderBoxModelObject::NormalizeAfterInsertion::No); 107 107 } 108 108 … … 125 125 RenderBlock* anonBlockHere = downcast<RenderBlock>(firstChildHere); 126 126 RenderBlock* anonBlockThere = downcast<RenderBlock>(lastChildThere); 127 anonBlockHere->moveAllChildrenTo(anonBlockThere, true);127 anonBlockHere->moveAllChildrenTo(anonBlockThere, RenderBoxModelObject::NormalizeAfterInsertion::Yes); 128 128 anonBlockHere->deleteLines(); 129 129 anonBlockHere->removeFromParentAndDestroy(); 130 130 } 131 131 // Move all remaining children normally. 132 moveChildrenTo(toBase, firstChild(), beforeChild );132 moveChildrenTo(toBase, firstChild(), beforeChild, RenderBoxModelObject::NormalizeAfterInsertion::No); 133 133 } 134 134 -
trunk/Source/WebCore/rendering/RenderRubyRun.cpp
r224537 r224933 168 168 // Collect all children in a single base, then swap the bases. 169 169 rightBase->mergeChildrenWithBase(*base); 170 moveChildTo(&rightRun, base );171 rightRun.moveChildTo(this, rightBase );170 moveChildTo(&rightRun, base, RenderBoxModelObject::NormalizeAfterInsertion::No); 171 rightRun.moveChildTo(this, rightBase, RenderBoxModelObject::NormalizeAfterInsertion::No); 172 172 // The now empty ruby base will be removed below. 173 173 ASSERT(!rubyBase()->firstChild()); -
trunk/Source/WebCore/rendering/RenderTableRow.cpp
r224546 r224933 315 315 continue; 316 316 } 317 currentRow->moveAllChildrenTo(rowToInsertInto );317 currentRow->moveAllChildrenTo(rowToInsertInto, RenderBoxModelObject::NormalizeAfterInsertion::No); 318 318 auto toDestroy = section->takeChild(*currentRow); 319 319 currentRow = currentRow->nextRow(); -
trunk/Source/WebCore/style/RenderTreeUpdaterMultiColumn.cpp
r222920 r224933 58 58 59 59 // Reparent children preceding the fragmented flow into the fragmented flow. 60 flow.moveChildrenTo(&fragmentedFlow, flow.firstChild(), &fragmentedFlow, true);60 flow.moveChildrenTo(&fragmentedFlow, flow.firstChild(), &fragmentedFlow, RenderBoxModelObject::NormalizeAfterInsertion::Yes); 61 61 if (flow.isFieldset()) { 62 62 // Keep legends out of the flow thread. 63 63 for (auto& box : childrenOfType<RenderBox>(fragmentedFlow)) { 64 64 if (box.isLegend()) 65 fragmentedFlow.moveChildTo(&flow, &box, true);65 fragmentedFlow.moveChildTo(&flow, &box, RenderBoxModelObject::NormalizeAfterInsertion::Yes); 66 66 } 67 67 } … … 76 76 77 77 fragmentedFlow.deleteLines(); 78 fragmentedFlow.moveAllChildrenTo(&flow, true);78 fragmentedFlow.moveAllChildrenTo(&flow, RenderBoxModelObject::NormalizeAfterInsertion::Yes); 79 79 80 80 // Move spanners back to their original DOM position in the tree, and destroy the placeholders.
Note: See TracChangeset
for help on using the changeset viewer.