Chromium Code Reviews| Index: third_party/WebKit/Source/core/layout/LayoutTable.cpp |
| diff --git a/third_party/WebKit/Source/core/layout/LayoutTable.cpp b/third_party/WebKit/Source/core/layout/LayoutTable.cpp |
| index 9ae716577e0dd6ffa1862617eff1887fbd144cd2..a7967d9a5e466831ba9e9132c2e20849f1dcd1e9 100644 |
| --- a/third_party/WebKit/Source/core/layout/LayoutTable.cpp |
| +++ b/third_party/WebKit/Source/core/layout/LayoutTable.cpp |
| @@ -298,7 +298,9 @@ void LayoutTable::updateLogicalWidth() { |
| marginStart, marginEnd, toLayoutBlockFlow(cb)); |
| // Ensure we aren't bigger than our available width. |
| - LayoutUnit maxWidth = maxPreferredLogicalWidth(); |
| + LayoutUnit maxWidth = hasStretchedLogicalWidth() |
| + ? availableContentLogicalWidth |
|
mstensho (USE GERRIT)
2016/11/28 12:54:31
Skipping maxPreferredLogicalWidth() here seems wro
jfernandez
2016/11/29 16:03:33
Done.
|
| + : maxPreferredLogicalWidth(); |
| // scaledWidthFromPercentColumns depends on m_layoutStruct in |
| // TableLayoutAlgorithmAuto, which maxPreferredLogicalWidth fills in. So |
| // scaledWidthFromPercentColumns has to be called after |
| @@ -461,11 +463,16 @@ void LayoutTable::layoutSection(LayoutTableSection& section, |
| LayoutUnit LayoutTable::logicalHeightFromStyle() const { |
| LayoutUnit computedLogicalHeight; |
| - Length logicalHeightLength = style()->logicalHeight(); |
| - if (logicalHeightLength.isIntrinsic() || |
| - (logicalHeightLength.isSpecified() && logicalHeightLength.isPositive())) { |
| - computedLogicalHeight = |
| - convertStyleLogicalHeightToComputedHeight(logicalHeightLength); |
| + if (hasOverrideLogicalContentHeight()) { |
| + computedLogicalHeight = overrideLogicalContentHeight(); |
| + } else { |
| + Length logicalHeightLength = style()->logicalHeight(); |
| + if (logicalHeightLength.isIntrinsic() || |
| + (logicalHeightLength.isSpecified() && |
| + logicalHeightLength.isPositive())) { |
| + computedLogicalHeight = |
| + convertStyleLogicalHeightToComputedHeight(logicalHeightLength); |
| + } |
| } |
| Length logicalMaxHeightLength = style()->logicalMaxHeight(); |