Index: third_party/WebKit/Source/core/layout/LayoutBox.cpp |
diff --git a/third_party/WebKit/Source/core/layout/LayoutBox.cpp b/third_party/WebKit/Source/core/layout/LayoutBox.cpp |
index b59cf4626abb3a6e4380f5724f7e55c2d0214412..9c341de0976cf47cb0cf05d47e1e8b4374ae72d7 100644 |
--- a/third_party/WebKit/Source/core/layout/LayoutBox.cpp |
+++ b/third_party/WebKit/Source/core/layout/LayoutBox.cpp |
@@ -2485,14 +2485,6 @@ void LayoutBox::computeLogicalWidth( |
if (treatAsReplaced) { |
computedValues.m_extent = |
LayoutUnit(logicalWidthLength.value()) + borderAndPaddingLogicalWidth(); |
- } else if (parent()->isLayoutGrid() && style()->logicalWidth().isAuto() && |
- style()->logicalMinWidth().isAuto() && |
- style()->overflowInlineDirection() == OverflowVisible && |
- containerWidthInInlineDirection < minPreferredLogicalWidth()) { |
- // TODO (lajava) Move this logic to the LayoutGrid class. |
- // Implied minimum size of Grid items. |
- computedValues.m_extent = constrainLogicalWidthByMinMax( |
- minPreferredLogicalWidth(), containerWidthInInlineDirection, cb); |
} else { |
LayoutUnit preferredWidth = |
computeLogicalWidthUsing(MainOrPreferredSize, styleToUse.logicalWidth(), |
@@ -2906,20 +2898,7 @@ void LayoutBox::computeLogicalHeight( |
// FIXME: Account for writing-mode in flexible boxes. |
// https://bugs.webkit.org/show_bug.cgi?id=46418 |
if (hasOverrideLogicalContentHeight()) { |
- LayoutUnit contentHeight = overrideLogicalContentHeight(); |
- if (parent()->isLayoutGrid() && style()->logicalMinHeight().isAuto() && |
- style()->overflowY() == OverflowVisible) { |
- ASSERT(style()->logicalHeight().isAuto()); |
- LayoutUnit minContentHeight = computeContentLogicalHeight( |
- MinSize, Length(MinContent), |
- computedValues.m_extent - borderAndPaddingLogicalHeight()); |
- contentHeight = std::max( |
- contentHeight, |
- constrainContentBoxLogicalHeightByMinMax( |
- minContentHeight, |
- computedValues.m_extent - borderAndPaddingLogicalHeight())); |
- } |
- h = Length(contentHeight, Fixed); |
+ h = Length(overrideLogicalContentHeight(), Fixed); |
} else if (treatAsReplaced) { |
h = Length(computeReplacedLogicalHeight(), Fixed); |
} else { |