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

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

Issue 1121173002: Fix shrink-to-fit when children's writing-mode is orthogonal (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: float tests added + cleanup a bit Created 5 years, 7 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
Index: Source/core/layout/LayoutBlockFlowLine.cpp
diff --git a/Source/core/layout/LayoutBlockFlowLine.cpp b/Source/core/layout/LayoutBlockFlowLine.cpp
index f50503df8f4ac7314d450abc495ec79108cc2260..e7f0d1d64b8c25ed44d9265f597a8bddb745c197 100644
--- a/Source/core/layout/LayoutBlockFlowLine.cpp
+++ b/Source/core/layout/LayoutBlockFlowLine.cpp
@@ -1320,15 +1320,7 @@ void LayoutBlockFlow::computeInlinePreferredLogicalWidths(LayoutUnit& minLogical
// Go ahead and terminate the current line as far as
// minwidth is concerned.
LayoutUnit childMinPreferredLogicalWidth, childMaxPreferredLogicalWidth;
- if (child->isBox() && child->isHorizontalWritingMode() != isHorizontalWritingMode()) {
- LayoutBox* childBox = toLayoutBox(child);
- LogicalExtentComputedValues computedValues;
- childBox->computeLogicalHeight(childBox->borderAndPaddingLogicalHeight(), 0, computedValues);
- childMinPreferredLogicalWidth = childMaxPreferredLogicalWidth = computedValues.m_extent;
- } else {
- childMinPreferredLogicalWidth = child->minPreferredLogicalWidth();
- childMaxPreferredLogicalWidth = child->maxPreferredLogicalWidth();
- }
+ minMaxPreferredLogicalWidthOfChild(*child, childMinPreferredLogicalWidth, childMaxPreferredLogicalWidth);
childMin += childMinPreferredLogicalWidth;
childMax += childMaxPreferredLogicalWidth;

Powered by Google App Engine
This is Rietveld 408576698