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

Unified Diff: third_party/WebKit/Source/core/layout/LayoutMultiColumnSpannerPlaceholder.cpp

Issue 1492993002: Support enclosing fragmentainer breaks inside spanners. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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
Index: third_party/WebKit/Source/core/layout/LayoutMultiColumnSpannerPlaceholder.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutMultiColumnSpannerPlaceholder.cpp b/third_party/WebKit/Source/core/layout/LayoutMultiColumnSpannerPlaceholder.cpp
index 327edd80770340e12563eca0d08e7c4df05f14f2..1da77af0f00867c031568e7cc55e5be0f9c685f8 100644
--- a/third_party/WebKit/Source/core/layout/LayoutMultiColumnSpannerPlaceholder.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutMultiColumnSpannerPlaceholder.cpp
@@ -91,6 +91,11 @@ void LayoutMultiColumnSpannerPlaceholder::layout()
{
ASSERT(needsLayout());
+ // The placeholder, like any other block level object, has its logical top calculated and set
+ // before layout. Copy this to the actual column-span:all object before laying it out, so that
+ // it gets paginated correctly, in case we have an enclosing fragmentation context.
+ m_layoutObjectInFlowThread->setLogicalTop(logicalTop());
+
// Lay out the actual column-span:all element.
m_layoutObjectInFlowThread->layoutIfNeeded();

Powered by Google App Engine
This is Rietveld 408576698