Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(627)

Unified Diff: Source/core/rendering/RenderBlock.cpp

Issue 20231002: Replace RenderArena with PartitionAlloc (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase. Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/rendering/RenderBlock.h ('k') | Source/core/rendering/RenderBlockLineLayout.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/RenderBlock.cpp
diff --git a/Source/core/rendering/RenderBlock.cpp b/Source/core/rendering/RenderBlock.cpp
index b969ed81dab7591e3d6b44b3466b3cfd82695fef..f66dd25698e619c1dc4533a04cd4aaa0f1b01d1c 100644
--- a/Source/core/rendering/RenderBlock.cpp
+++ b/Source/core/rendering/RenderBlock.cpp
@@ -269,7 +269,7 @@ RenderBlock::~RenderBlock()
RenderBlock* RenderBlock::createAnonymous(Document* document)
{
- RenderBlock* renderer = new (document->renderArena()) RenderBlock(0);
+ RenderBlock* renderer = new RenderBlock(0);
renderer->setDocumentForAnonymous(document);
return renderer;
}
@@ -324,10 +324,10 @@ void RenderBlock::willBeDestroyed()
parent()->dirtyLinesFromChangedChild(this);
}
- m_lineBoxes.deleteLineBoxes(renderArena());
+ m_lineBoxes.deleteLineBoxes();
if (lineGridBox())
- lineGridBox()->destroy(renderArena());
+ lineGridBox()->destroy();
if (UNLIKELY(gDelayedUpdateScrollInfoSet != 0))
gDelayedUpdateScrollInfoSet->remove(this);
@@ -734,9 +734,6 @@ void RenderBlock::splitFlow(RenderObject* beforeChild, RenderBlock* newBlockBox,
// time in makeChildrenNonInline by just setting this explicitly up front.
newBlockBox->setChildrenInline(false);
- // We delayed adding the newChild until now so that the |newBlockBox| would be fully
- // connected, thus allowing newChild access to a renderArena should it need
- // to wrap itself in additional boxes (e.g., table construction).
newBlockBox->addChild(newChild);
// Always just do a full layout in order to ensure that line boxes (especially wrappers for images)
@@ -786,9 +783,6 @@ void RenderBlock::makeChildrenAnonymousColumnBlocks(RenderObject* beforeChild, R
// time in makeChildrenNonInline by just setting this explicitly up front.
newBlockBox->setChildrenInline(false);
- // We delayed adding the newChild until now so that the |newBlockBox| would be fully
- // connected, thus allowing newChild access to a renderArena should it need
- // to wrap itself in additional boxes (e.g., table construction).
newBlockBox->addChild(newChild);
// Always just do a full layout in order to ensure that line boxes (especially wrappers for images)
@@ -1026,7 +1020,7 @@ void RenderBlock::deleteLineBoxTree()
(*it)->m_originatingLine = 0;
}
}
- m_lineBoxes.deleteLineBoxTree(renderArena());
+ m_lineBoxes.deleteLineBoxTree();
if (AXObjectCache* cache = document()->existingAXObjectCache())
cache->recomputeIsIgnored(this);
@@ -1034,7 +1028,7 @@ void RenderBlock::deleteLineBoxTree()
RootInlineBox* RenderBlock::createRootInlineBox()
{
- return new (renderArena()) RootInlineBox(this);
+ return new RootInlineBox(this);
}
RootInlineBox* RenderBlock::createAndAppendRootInlineBox()
@@ -1952,9 +1946,9 @@ RenderBoxModelObject* RenderBlock::createReplacementRunIn(RenderBoxModelObject*
RenderBoxModelObject* newRunIn = 0;
if (!runIn->isRenderBlock())
- newRunIn = new (renderArena()) RenderBlock(runIn->node());
+ newRunIn = new RenderBlock(runIn->node());
else
- newRunIn = new (renderArena()) RenderInline(toElement(runIn->node()));
+ newRunIn = new RenderInline(toElement(runIn->node()));
runIn->node()->setRenderer(newRunIn);
newRunIn->setStyle(runIn->style());
@@ -6791,7 +6785,7 @@ void RenderBlock::createFirstLetterRenderer(RenderObject* firstLetterBlock, Rend
// Construct a text fragment for the text after the first letter.
// This text fragment might be empty.
RenderTextFragment* remainingText =
- new (renderArena()) RenderTextFragment(textObj->node() ? textObj->node() : textObj->document(), oldText.get(), length, oldText->length() - length);
+ new RenderTextFragment(textObj->node() ? textObj->node() : textObj->document(), oldText.get(), length, oldText->length() - length);
remainingText->setStyle(textObj->style());
if (remainingText->node())
remainingText->node()->setRenderer(remainingText);
@@ -6803,7 +6797,7 @@ void RenderBlock::createFirstLetterRenderer(RenderObject* firstLetterBlock, Rend
// construct text fragment for the first letter
RenderTextFragment* letter =
- new (renderArena()) RenderTextFragment(remainingText->node() ? remainingText->node() : remainingText->document(), oldText.get(), 0, length);
+ new RenderTextFragment(remainingText->node() ? remainingText->node() : remainingText->document(), oldText.get(), 0, length);
letter->setStyle(pseudoStyle);
firstLetter->addChild(letter);
« no previous file with comments | « Source/core/rendering/RenderBlock.h ('k') | Source/core/rendering/RenderBlockLineLayout.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698