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

Unified Diff: Source/core/layout/LayoutMultiColumnFlowThread.cpp

Issue 1320843005: Update outer flow thread membership before changing multicolness. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 4 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/layout/LayoutMultiColumnFlowThread.h ('k') | Source/core/layout/LayoutObject.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/layout/LayoutMultiColumnFlowThread.cpp
diff --git a/Source/core/layout/LayoutMultiColumnFlowThread.cpp b/Source/core/layout/LayoutMultiColumnFlowThread.cpp
index 478f89d9d701fd067c66d0e799cfbdb7284497dc..f698ee8be1a0da2099ee9419d23a346deae286d4 100644
--- a/Source/core/layout/LayoutMultiColumnFlowThread.cpp
+++ b/Source/core/layout/LayoutMultiColumnFlowThread.cpp
@@ -837,42 +837,28 @@ static inline bool needsToInsertIntoFlowThread(const ComputedStyle& oldStyle, co
return (!newStyle.hasOutOfFlowPosition() && oldStyle.hasOutOfFlowPosition()) || needsToReinsertIntoFlowThread(oldStyle, newStyle);
}
-void LayoutMultiColumnFlowThread::flowThreadDescendantStyleWillChange(LayoutObject* descendant, StyleDifference diff, const ComputedStyle& newStyle)
+void LayoutMultiColumnFlowThread::flowThreadDescendantStyleWillChange(LayoutBox* descendant, StyleDifference diff, const ComputedStyle& newStyle)
{
- if (descendant->isText()) {
- // Text nodes inherit all properties from the parent node (including non-inheritable
- // ones). We don't care what its 'position' is. In fact, we _must_ ignore it, since the
- // parent may be the multicol container, and having that accidentally leaked into children
- // of the multicol is bad.
- return;
- }
if (needsToRemoveFromFlowThread(descendant->styleRef(), newStyle))
flowThreadDescendantWillBeRemoved(descendant);
}
-void LayoutMultiColumnFlowThread::flowThreadDescendantStyleDidChange(LayoutObject* descendant, StyleDifference diff, const ComputedStyle& oldStyle)
+void LayoutMultiColumnFlowThread::flowThreadDescendantStyleDidChange(LayoutBox* descendant, StyleDifference diff, const ComputedStyle& oldStyle)
{
- if (descendant->isText()) {
- // Text nodes inherit all properties from the parent node (including non-inheritable
- // ones). We don't care what its 'position' is. In fact, we _must_ ignore it, since the
- // parent may be the multicol container, and having that accidentally leaked into children
- // of the multicol is bad.
- return;
- }
if (needsToInsertIntoFlowThread(oldStyle, descendant->styleRef())) {
flowThreadDescendantWasInserted(descendant);
return;
}
if (descendantIsValidColumnSpanner(descendant)) {
// We went from being regular column content to becoming a spanner.
- ASSERT(!toLayoutBox(descendant)->spannerPlaceholder());
+ ASSERT(!descendant->spannerPlaceholder());
// First remove this as regular column content. Note that this will walk the entire subtree
// of |descendant|. There might be spanners there (which won't be spanners anymore, since
// we're not allowed to nest spanners), whose placeholders must die.
flowThreadDescendantWillBeRemoved(descendant);
- createAndInsertSpannerPlaceholder(toLayoutBox(descendant), nextInPreOrderAfterChildrenSkippingOutOfFlow(this, descendant));
+ createAndInsertSpannerPlaceholder(descendant, nextInPreOrderAfterChildrenSkippingOutOfFlow(this, descendant));
}
}
« no previous file with comments | « Source/core/layout/LayoutMultiColumnFlowThread.h ('k') | Source/core/layout/LayoutObject.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698