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

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

Issue 190973007: Reland "Avoid layout/full-repaint on view height change if possible" (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: New CL Created 6 years, 9 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
Index: Source/core/rendering/RenderBox.cpp
diff --git a/Source/core/rendering/RenderBox.cpp b/Source/core/rendering/RenderBox.cpp
index 4a2d54b7400e91504c480135fbf3b3e1b727fabb..60ece9d82187a1107b570e2a2a3a2a2834a4164e 100644
--- a/Source/core/rendering/RenderBox.cpp
+++ b/Source/core/rendering/RenderBox.cpp
@@ -2708,8 +2708,8 @@ LayoutUnit RenderBox::computePercentageLogicalHeight(const Length& height) const
skippedAutoHeightContainingBlock = true;
containingBlockChild = cb;
cb = cb->containingBlock();
- cb->addPercentHeightDescendant(const_cast<RenderBox*>(this));
}
+ cb->addPercentHeightDescendant(const_cast<RenderBox*>(this));
esprehn 2014/03/10 21:32:30 Same, why is it okay to skip adding percentage hei
Xianzhu 2014/03/11 00:55:13 In existing code, percentHeightDescendants is used
RenderStyle* cbstyle = cb->style();
@@ -2861,10 +2861,10 @@ LayoutUnit RenderBox::computeReplacedLogicalHeightUsing(Length logicalHeight) co
case Calculated:
{
RenderObject* cb = isOutOfFlowPositioned() ? container() : containingBlock();
- while (cb->isAnonymous()) {
+ while (cb->isAnonymous())
cb = cb->containingBlock();
+ if (cb->isRenderBlock())
esprehn 2014/03/10 21:32:30 This skips adding anonymous percentage height desc
Xianzhu 2014/03/11 00:55:13 Actually this skips adding this object into percen
toRenderBlock(cb)->addPercentHeightDescendant(const_cast<RenderBox*>(this));
- }
// FIXME: This calculation is not patched for block-flow yet.
// https://bugs.webkit.org/show_bug.cgi?id=46500

Powered by Google App Engine
This is Rietveld 408576698