Chromium Code Reviews| Index: third_party/WebKit/Source/core/layout/ng/ng_constraint_space.cc |
| diff --git a/third_party/WebKit/Source/core/layout/ng/ng_constraint_space.cc b/third_party/WebKit/Source/core/layout/ng/ng_constraint_space.cc |
| index 5af006f4649233d7cc55059be4c0fa0b5c8e8fce..171252924919dce2cee4ff6c318fc4071e9f3328 100644 |
| --- a/third_party/WebKit/Source/core/layout/ng/ng_constraint_space.cc |
| +++ b/third_party/WebKit/Source/core/layout/ng/ng_constraint_space.cc |
| @@ -52,6 +52,8 @@ NGConstraintSpace* NGConstraintSpace::CreateFromLayoutObject( |
| available_logical_height = |
| box.containingBlock()->availableLogicalHeightForPercentageComputation(); |
| } |
| + NGLogicalSize percentage_size = {available_logical_width, |
| + available_logical_height}; |
|
cbiesinger
2017/01/10 19:45:03
While you're touching this, I'd also make this oth
atotic
2017/01/10 21:53:20
done
|
| // When we have an override size, the available_logical_{width,height} will be |
| // used as the final size of the box, so it has to include border and |
| // padding. |
| @@ -73,7 +75,7 @@ NGConstraintSpace* NGConstraintSpace::CreateFromLayoutObject( |
| auto writing_mode = FromPlatformWritingMode(box.styleRef().getWritingMode()); |
| return NGConstraintSpaceBuilder(writing_mode) |
| .SetAvailableSize(size) |
| - .SetPercentageResolutionSize(size) |
| + .SetPercentageResolutionSize(percentage_size) |
| .SetIsInlineDirectionTriggersScrollbar( |
| box.styleRef().overflowInlineDirection() == EOverflow::Auto) |
| .SetIsBlockDirectionTriggersScrollbar( |