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

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

Issue 2961583003: Element with columnCount > 1 should be classified as INDEPENDENT (Closed)
Patch Set: nit Created 3 years, 6 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 | « no previous file | third_party/WebKit/Source/core/layout/TextAutosizerTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/layout/TextAutosizer.cpp
diff --git a/third_party/WebKit/Source/core/layout/TextAutosizer.cpp b/third_party/WebKit/Source/core/layout/TextAutosizer.cpp
index 873eaf3b79237b3e3b82489f54a6231ba23fb72a..a7f828c5c517f531abe7620f0c897168cef64e05 100644
--- a/third_party/WebKit/Source/core/layout/TextAutosizer.cpp
+++ b/third_party/WebKit/Source/core/layout/TextAutosizer.cpp
@@ -41,6 +41,7 @@
#include "core/layout/LayoutInline.h"
#include "core/layout/LayoutListItem.h"
#include "core/layout/LayoutListMarker.h"
+#include "core/layout/LayoutMultiColumnFlowThread.h"
#include "core/layout/LayoutRubyRun.h"
#include "core/layout/LayoutTable.h"
#include "core/layout/LayoutTableCell.h"
@@ -675,8 +676,12 @@ TextAutosizer::BlockFlags TextAutosizer::ClassifyBlock(
if (mask & POTENTIAL_ROOT)
flags |= POTENTIAL_ROOT;
+ LayoutMultiColumnFlowThread* flow_thread = nullptr;
+ if (block->IsLayoutBlockFlow())
+ flow_thread = ToLayoutBlockFlow(block)->MultiColumnFlowThread();
if ((mask & INDEPENDENT) &&
- (IsIndependentDescendant(block) || block->IsTable()))
+ (IsIndependentDescendant(block) || block->IsTable() ||
+ (flow_thread && flow_thread->ColumnCount() > 1)))
flags |= INDEPENDENT;
if ((mask & EXPLICIT_WIDTH) && HasExplicitWidth(block))
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/layout/TextAutosizerTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698