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

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

Issue 789433006: [New Multicolumn] Let a spanner's containing block be the multicol container. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Compiling release: paint invalidation state is cleared in the super class anyway. Created 6 years 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.h ('k') | Source/core/rendering/RenderBox.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/RenderBlockFlow.cpp
diff --git a/Source/core/rendering/RenderBlockFlow.cpp b/Source/core/rendering/RenderBlockFlow.cpp
index ace7c2d43f56633d9b8cdfd3900a51c68c072d3d..580c9b24546acd287f74bac660d43a247f1084a8 100644
--- a/Source/core/rendering/RenderBlockFlow.cpp
+++ b/Source/core/rendering/RenderBlockFlow.cpp
@@ -42,6 +42,7 @@
#include "core/rendering/RenderFlowThread.h"
#include "core/rendering/RenderLayer.h"
#include "core/rendering/RenderMultiColumnFlowThread.h"
+#include "core/rendering/RenderMultiColumnSpannerPlaceholder.h"
#include "core/rendering/RenderPagedFlowThread.h"
#include "core/rendering/RenderText.h"
#include "core/rendering/RenderView.h"
@@ -1057,6 +1058,11 @@ void RenderBlockFlow::layoutBlockChildren(bool relayoutChildren, SubtreeLayoutSc
adjustFloatingBlock(marginInfo);
continue;
}
+ if (child->isColumnSpanAll()) {
+ // This is not the containing block of the spanner. The spanner's placeholder will lay
+ // it out in due course.
+ continue;
+ }
// Lay out the child.
layoutBlockChild(*child, marginInfo, previousFloatLogicalBottom);
@@ -1971,6 +1977,16 @@ void RenderBlockFlow::styleDidChange(StyleDifference diff, const RenderStyle* ol
createOrDestroyMultiColumnFlowThreadIfNeeded(oldStyle);
}
+void RenderBlockFlow::updateBlockChildDirtyBitsBeforeLayout(bool relayoutChildren, RenderBox& child)
+{
+ if (child.isRenderMultiColumnSpannerPlaceholder() && toRenderMultiColumnSpannerPlaceholder(child).rendererInFlowThread()->needsLayout()) {
+ // The containing block of a spanner is the multicol container (|this| block), but the spanner
+ // is laid out via its spanner set (|child|), so we need to make sure that we enter it.
+ child.setChildNeedsLayout(MarkOnlyThis);
+ }
+ RenderBlock::updateBlockChildDirtyBitsBeforeLayout(relayoutChildren, child);
+}
+
void RenderBlockFlow::updateStaticInlinePositionForChild(RenderBox& child, LayoutUnit logicalTop)
{
if (child.style()->isOriginalDisplayInlineType())
« no previous file with comments | « Source/core/rendering/RenderBlockFlow.h ('k') | Source/core/rendering/RenderBox.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698