| 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 7e8e1228e73f6981aec8d7c559cb5f9e5950b987..d27c6f733ed88b8c4e49c6cd23dbb00ce3ca54bd 100644
|
| --- a/third_party/WebKit/Source/core/layout/LayoutTable.cpp
|
| +++ b/third_party/WebKit/Source/core/layout/LayoutTable.cpp
|
| @@ -282,7 +282,13 @@ void LayoutTable::updateLogicalWidth()
|
| availableContentLogicalWidth = shrinkLogicalWidthToAvoidFloats(marginStart, marginEnd, toLayoutBlockFlow(cb));
|
|
|
| // Ensure we aren't bigger than our available width.
|
| - setLogicalWidth(LayoutUnit(std::min(availableContentLogicalWidth, maxPreferredLogicalWidth()).floor()));
|
| + LayoutUnit maxWidth = maxPreferredLogicalWidth();
|
| + // scaledWidthFromPercentColumns depends on m_layoutStruct in TableLayoutAlgorithmAuto, which
|
| + // maxPreferredLogicalWidth fills in. So scaledWidthFromPercentColumns has to be called after
|
| + // maxPreferredLogicalWidth.
|
| + LayoutUnit scaledWidth = m_tableLayout->scaledWidthFromPercentColumns() + bordersPaddingAndSpacingInRowDirection();
|
| + maxWidth = std::max(scaledWidth, maxWidth);
|
| + setLogicalWidth(LayoutUnit(std::min(availableContentLogicalWidth, maxWidth).floor()));
|
| }
|
|
|
| // Ensure we aren't bigger than our max-width style.
|
|
|