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

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

Issue 551263005: *** DO NOT LAND *** Implement column-span:all without reparenting renderers. Work in progress. (Closed) Base URL: git:blink.git@new-multicol-no-renderer-reparenting
Patch Set: Copy margin properties from a spanner to its spanner set, to simplify code. Created 6 years, 3 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/RenderBlockFlow.cpp ('k') | Source/core/rendering/RenderFlowThread.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/RenderBox.cpp
diff --git a/Source/core/rendering/RenderBox.cpp b/Source/core/rendering/RenderBox.cpp
index 96d8174c1fb0bd499123ce3b368f811f14d92b4e..45ec1607f3e0251c2ecaee8e2d797ecbddd7530c 100644
--- a/Source/core/rendering/RenderBox.cpp
+++ b/Source/core/rendering/RenderBox.cpp
@@ -225,6 +225,11 @@ void RenderBox::styleDidChange(StyleDifference diff, const RenderStyle* oldStyle
updateShapeOutsideInfoAfterStyleChange(*style(), oldStyle);
updateGridPositionAfterStyleChange(oldStyle);
+
+ if (RenderFlowThread* flowThread = flowThreadContainingBlock()) {
+ if (flowThread != this)
+ flowThread->flowThreadDescendantStyleDidChange(this);
+ }
}
void RenderBox::updateShapeOutsideInfoAfterStyleChange(const RenderStyle& style, const RenderStyle* oldStyle)
@@ -2345,7 +2350,7 @@ bool RenderBox::autoWidthShouldFitContent() const
void RenderBox::computeMarginsForDirection(MarginDirection flowDirection, const RenderBlock* containingBlock, LayoutUnit containerWidth, LayoutUnit childWidth, LayoutUnit& marginStart, LayoutUnit& marginEnd, Length marginStartLength, Length marginEndLength) const
{
if (flowDirection == BlockDirection || isFloating() || isInline()) {
- if (isTableCell() && flowDirection == BlockDirection) {
+ if ((isColumnSpanAll() || isTableCell()) && flowDirection == BlockDirection) {
// FIXME: Not right if we allow cells to have different directionality than the table. If we do allow this, though,
// we may just do it with an extra anonymous block inside the cell.
marginStart = 0;
@@ -4470,14 +4475,8 @@ LayoutRect RenderBox::layoutOverflowRectForPropagation(RenderStyle* parentStyle)
LayoutRect rect = borderBoxRect();
// We want to include the margin, but only when it adds height. Quirky margins don't contribute height
// nor do the margins of self-collapsing blocks.
- if (!style()->hasMarginAfterQuirk() && !isSelfCollapsingBlock()) {
- LayoutState* layoutState = view()->layoutState();
- // FIXME: if the margin has collapsed with a page/column boundary, the part that got
- // collapsed away must not be propagated here. All other margins should be propagated,
- // though, but for now, we just ignore them in paginated mode.
- if (!layoutState || !layoutState->isPaginated())
- rect.expand(isHorizontalWritingMode() ? LayoutSize(LayoutUnit(), marginAfter()) : LayoutSize(marginAfter(), LayoutUnit()));
- }
+ if (!style()->hasMarginAfterQuirk() && !isSelfCollapsingBlock())
+ rect.expand(isHorizontalWritingMode() ? LayoutSize(LayoutUnit(), marginAfter()) : LayoutSize(marginAfter(), LayoutUnit()));
if (!hasOverflowClip())
rect.unite(layoutOverflowRect());
« no previous file with comments | « Source/core/rendering/RenderBlockFlow.cpp ('k') | Source/core/rendering/RenderFlowThread.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698