Changeset 273072 in webkit


Ignore:
Timestamp:
Feb 18, 2021 1:58:39 AM (17 months ago)
Author:
svillar@igalia.com
Message:

[css-flex] Implement section 9.8 Definite and Indefinite Sizes case 1
https://bugs.webkit.org/show_bug.cgi?id=219538
<rdar://problem/72136484>

Reviewed by Manuel Rego Casasnovas.

LayoutTests/imported/w3c:

  • web-platform-tests/css/css-flexbox/flex-aspect-ratio-img-row-013-expected.txt: Replaced FAIL by PASS expectations.
  • web-platform-tests/css/css-flexbox/image-as-flexitem-size-003-expected.txt: Ditto.
  • web-platform-tests/css/css-flexbox/image-as-flexitem-size-003v-expected.txt: Ditto.
  • web-platform-tests/css/css-flexbox/image-as-flexitem-size-004-expected.txt: Ditto.
  • web-platform-tests/css/css-flexbox/image-as-flexitem-size-004v-expected.txt: Ditto.
  • web-platform-tests/css/css-sizing/percentage-height-in-flexbox.html: Updated expectation. Still failing.

Source/WebCore:

If a single-line flex container has a definite cross size, the automatic preferred outer cross size
of any stretched flex items is the flex container's inner cross size (clamped to the flex item's
min and max cross size) and is considered definite. Before that we were considering all automatic
sizes as indefinite (see https://drafts.csswg.org/css-flexbox/#definite-sizes).

This patch does not consider all the cases where the container cross size is definite but just when
that size is fixed. Support for additional cases should be added in followup patches.

This change unveiled an implementation mistake when computing content sizes for the min-size:auto case.
In those cases we were always calling computeMainAxisExtentForChild() but that does not take into
account the aspect ratio, that's why we added an additional code path which computes the content
size using computeMainSizeFromAspectRatioUsing() instead.

This fixes 8 full tests plus 24 subtests in some other flexbox aspect ratio tests from the WPT suite.

  • rendering/RenderFlexibleBox.cpp:

(WebCore::RenderFlexibleBox::useChildAspectRatio const): Use ternary operator to simplify code.
(WebCore::RenderFlexibleBox::computeMainSizeFromAspectRatioUsing const): Resolve child size to container's
size if childCrossSizeShouldUseContainerCrossSize().
(WebCore::RenderFlexibleBox::childCrossSizeShouldUseContainerCrossSize const): New method implementing
section 9.8.1 of the specs.
(WebCore::RenderFlexibleBox::childCrossSizeIsDefinite const):
(WebCore::RenderFlexibleBox::computeInnerFlexBaseSizeForChild): Use aspect ratio to compute cross size
also if childCrossSizeShouldUseContainerCrossSize().
(WebCore::RenderFlexibleBox::adjustChildSizeForMinAndMax): Use aspect ratio specific code to compute
content size if aspect ratio should be used for child.
(WebCore::RenderFlexibleBox::adjustChildSizeForAspectRatioCrossAxisMinAndMax):

  • rendering/RenderFlexibleBox.h:

LayoutTests:

Location:
trunk
Files:
12 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r273071 r273072  
     12021-02-15  Sergio Villar Senin  <svillar@igalia.com>
     2
     3        [css-flex] Implement section 9.8 Definite and Indefinite Sizes case 1
     4        https://bugs.webkit.org/show_bug.cgi?id=219538
     5        <rdar://problem/72136484>
     6
     7        Reviewed by Manuel Rego Casasnovas.
     8
     9        * TestExpectations: Unskipped 8 tests that are passing now.
     10
    1112021-02-18  Youenn Fablet  <youenn@apple.com>
    212
  • trunk/LayoutTests/TestExpectations

    r273065 r273072  
    39193919webkit.org/b/219343 imported/w3c/web-platform-tests/css/css-flexbox/flex-aspect-ratio-img-column-015.html [ ImageOnlyFailure ]
    39203920webkit.org/b/219343 imported/w3c/web-platform-tests/css/css-flexbox/flex-aspect-ratio-img-column-017.html [ ImageOnlyFailure ]
    3921 webkit.org/b/219343 imported/w3c/web-platform-tests/css/css-flexbox/flex-aspect-ratio-img-row-006.html [ ImageOnlyFailure ]
    39223921webkit.org/b/219343 imported/w3c/web-platform-tests/css/css-flexbox/flex-aspect-ratio-img-row-007.html [ ImageOnlyFailure ]
    39233922webkit.org/b/219343 imported/w3c/web-platform-tests/css/css-flexbox/flex-aspect-ratio-img-row-010.html [ ImageOnlyFailure ]
     
    39293928webkit.org/b/210144 imported/w3c/web-platform-tests/css/css-flexbox/anonymous-flex-item-005.html [ ImageOnlyFailure ]
    39303929webkit.org/b/210478 imported/w3c/web-platform-tests/css/css-flexbox/percentage-heights-006.html [ ImageOnlyFailure ]
    3931 webkit.org/b/212046 imported/w3c/web-platform-tests/css/css-flexbox/flex-minimum-height-flex-items-007.xht [ ImageOnlyFailure ]
    3932 webkit.org/b/212046 imported/w3c/web-platform-tests/css/css-flexbox/flex-minimum-width-flex-items-007.xht [ ImageOnlyFailure ]
    39333930webkit.org/b/212046 imported/w3c/web-platform-tests/css/css-flexbox/overflow-area-001.html [ ImageOnlyFailure ]
    39343931webkit.org/b/212046 imported/w3c/web-platform-tests/css/css-flexbox/overflow-area-002.html [ ImageOnlyFailure ]
     
    40494046
    40504047# min-size:auto in flexbox.
    4051 webkit.org/b/221481 imported/w3c/web-platform-tests/css/css-flexbox/flexbox-min-height-auto-002a.html [ ImageOnlyFailure ]
    4052 webkit.org/b/221481 imported/w3c/web-platform-tests/css/css-flexbox/flexbox-min-height-auto-002c.html [ ImageOnlyFailure ]
    4053 webkit.org/b/221481 imported/w3c/web-platform-tests/css/css-flexbox/flexbox-min-width-auto-002a.html [ ImageOnlyFailure ]
    4054 webkit.org/b/221481 imported/w3c/web-platform-tests/css/css-flexbox/flexbox-min-width-auto-002c.html [ ImageOnlyFailure ]
    4055 webkit.org/b/221481 imported/w3c/web-platform-tests/css/css-flexbox/flexbox-min-width-auto-005.html [ ImageOnlyFailure ]
    40564048webkit.org/b/221481 imported/w3c/web-platform-tests/css/css-flexbox/flex-minimum-height-flex-items-026.html [ ImageOnlyFailure ]
    40574049webkit.org/b/221481 imported/w3c/web-platform-tests/css/css-flexbox/flex-minimum-height-flex-items-029.html [ ImageOnlyFailure ]
  • trunk/LayoutTests/imported/w3c/ChangeLog

    r273068 r273072  
     12021-02-15  Sergio Villar Senin  <svillar@igalia.com>
     2
     3        [css-flex] Implement section 9.8 Definite and Indefinite Sizes case 1
     4        https://bugs.webkit.org/show_bug.cgi?id=219538
     5        <rdar://problem/72136484>
     6
     7        Reviewed by Manuel Rego Casasnovas.
     8
     9        * web-platform-tests/css/css-flexbox/flex-aspect-ratio-img-row-013-expected.txt: Replaced FAIL by PASS expectations.
     10        * web-platform-tests/css/css-flexbox/image-as-flexitem-size-003-expected.txt: Ditto.
     11        * web-platform-tests/css/css-flexbox/image-as-flexitem-size-003v-expected.txt: Ditto.
     12        * web-platform-tests/css/css-flexbox/image-as-flexitem-size-004-expected.txt: Ditto.
     13        * web-platform-tests/css/css-flexbox/image-as-flexitem-size-004v-expected.txt: Ditto.
     14        * web-platform-tests/css/css-sizing/percentage-height-in-flexbox.html: Updated expectation. Still failing.
     15
    1162021-02-18  Rob Buis  <rbuis@igalia.com>
    217
  • trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-flexbox/flex-aspect-ratio-img-column-011-expected.txt

    r270237 r273072  
    44PASS .flexbox 3
    55PASS .flexbox 4
    6 FAIL .flexbox 5 assert_equals:
    7 <div class="flexbox" style="width: 10px;" data-expected-width="10">
    8     <!-- transferred and content suggestions are both 100px here, so minimum
    9       width is min(transferred, content width) = 100px. -->
    10     <img src="support/10x10-green.png" style="height: 100px;" data-expected-width="100">
    11 </div>
    12 width expected 100 but got 10
     6PASS .flexbox 5
    137PASS .flexbox 6
    148PASS .flexbox 7
    159PASS .flexbox 8
    1610PASS .flexbox 9
    17 FAIL .flexbox 10 assert_equals:
    18 <div class="flexbox column" style="height: 10px;" data-expected-height="10">
    19     <!-- should use min(transferred (100), content height (100)) = 100px as
    20          minimum height, which will be final height of the image -->
    21     <img src="support/10x10-green.png" style="width: 100px;" data-expected-height="100">
    22 </div>
    23 height expected 100 but got 10
     11PASS .flexbox 10
    2412
    2513
  • trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-flexbox/flex-aspect-ratio-img-row-013-expected.txt

    r272755 r273072  
    1313
    1414
    15 FAIL img 1 assert_equals:
    16 <img src="support/200x200-green.png" data-expected-height="100" data-expected-width="100">
    17 width expected 100 but got 200
     15PASS img 1
    1816FAIL img 2 assert_equals:
    1917<img src="support/200x200-green.png" style="margin-bottom: 20px" data-expected-height="100" data-expected-width="100">
    20 width expected 100 but got 200
    21 FAIL img 3 assert_equals:
    22 <img src="support/200x200-green.png" style="min-height: 100px;" data-expected-height="100" data-expected-width="100">
    23 width expected 100 but got 200
     18width expected 100 but got 120
     19PASS img 3
    2420
  • trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-flexbox/image-as-flexitem-size-003-expected.txt

    r272755 r273072  
    66
    77
    8 FAIL .flexbox > img 1 assert_equals:
    9 <img src="support/solidblue.png" data-expected-width="40" data-expected-height="40">
    10 width expected 40 but got 16
     8PASS .flexbox > img 1
    119PASS .flexbox > img 2
    1210PASS .flexbox > img 3
    1311PASS .flexbox > img 4
    14 FAIL .flexbox > img 5 assert_equals:
    15 <img src="support/solidblue.png" style="min-width: 34px" data-expected-width="40" data-expected-height="40">
    16 width expected 40 but got 34
    17 FAIL .flexbox > img 6 assert_equals:
    18 <img src="support/solidblue.png" style="min-height: 34px" data-expected-width="40" data-expected-height="40">
    19 width expected 40 but got 34
    20 FAIL .flexbox > img 7 assert_equals:
    21 <img src="support/solidblue.png" style="min-width: 30px;
    22                                               min-height: 34px" data-expected-width="40" data-expected-height="40">
    23 width expected 40 but got 34
    24 FAIL .flexbox > img 8 assert_equals:
    25 <img src="support/solidblue.png" style="min-width: 34px;
    26                                               min-height: 30px" data-expected-width="40" data-expected-height="40">
    27 width expected 40 but got 34
     12PASS .flexbox > img 5
     13PASS .flexbox > img 6
     14PASS .flexbox > img 7
     15PASS .flexbox > img 8
    2816PASS .flexbox > img 9
    2917PASS .flexbox > img 10
  • trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-flexbox/image-as-flexitem-size-003v-expected.txt

    r272755 r273072  
    66
    77
    8 FAIL .flexbox > img 1 assert_equals:
    9 <img src="support/solidblue.png" data-expected-width="40" data-expected-height="40">
    10 width expected 40 but got 16
     8PASS .flexbox > img 1
    119PASS .flexbox > img 2
    1210PASS .flexbox > img 3
    1311PASS .flexbox > img 4
    14 FAIL .flexbox > img 5 assert_equals:
    15 <img src="support/solidblue.png" style="min-width: 34px" data-expected-width="40" data-expected-height="40">
    16 width expected 40 but got 34
    17 FAIL .flexbox > img 6 assert_equals:
    18 <img src="support/solidblue.png" style="min-height: 34px" data-expected-width="40" data-expected-height="40">
    19 width expected 40 but got 34
    20 FAIL .flexbox > img 7 assert_equals:
    21 <img src="support/solidblue.png" style="min-width: 30px;
    22                                               min-height: 34px" data-expected-width="40" data-expected-height="40">
    23 width expected 40 but got 34
    24 FAIL .flexbox > img 8 assert_equals:
    25 <img src="support/solidblue.png" style="min-width: 34px;
    26                                               min-height: 30px" data-expected-width="40" data-expected-height="40">
    27 width expected 40 but got 34
     12PASS .flexbox > img 5
     13PASS .flexbox > img 6
     14PASS .flexbox > img 7
     15PASS .flexbox > img 8
    2816PASS .flexbox > img 9
    2917PASS .flexbox > img 10
  • trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-flexbox/image-as-flexitem-size-004-expected.txt

    r272755 r273072  
    66
    77
    8 FAIL .flexbox > img 1 assert_equals:
    9 <img src="support/solidblue.png" data-expected-width="40" data-expected-height="40">
    10 height expected 40 but got 16
     8PASS .flexbox > img 1
    119PASS .flexbox > img 2
    1210PASS .flexbox > img 3
    1311PASS .flexbox > img 4
    14 FAIL .flexbox > img 5 assert_equals:
    15 <img src="support/solidblue.png" style="min-width: 34px" data-expected-width="40" data-expected-height="40">
    16 height expected 40 but got 34
    17 FAIL .flexbox > img 6 assert_equals:
    18 <img src="support/solidblue.png" style="min-height: 34px" data-expected-width="40" data-expected-height="40">
    19 height expected 40 but got 34
    20 FAIL .flexbox > img 7 assert_equals:
    21 <img src="support/solidblue.png" style="min-width: 30px;
    22                                               min-height: 34px" data-expected-width="40" data-expected-height="40">
    23 height expected 40 but got 34
    24 FAIL .flexbox > img 8 assert_equals:
    25 <img src="support/solidblue.png" style="min-width: 34px;
    26                                               min-height: 30px" data-expected-width="40" data-expected-height="40">
    27 height expected 40 but got 34
     12PASS .flexbox > img 5
     13PASS .flexbox > img 6
     14PASS .flexbox > img 7
     15PASS .flexbox > img 8
    2816PASS .flexbox > img 9
    2917PASS .flexbox > img 10
  • trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-flexbox/image-as-flexitem-size-004v-expected.txt

    r272755 r273072  
    66
    77
    8 FAIL .flexbox > img 1 assert_equals:
    9 <img src="support/solidblue.png" data-expected-width="40" data-expected-height="40">
    10 height expected 40 but got 16
     8PASS .flexbox > img 1
    119PASS .flexbox > img 2
    1210PASS .flexbox > img 3
    1311PASS .flexbox > img 4
    14 FAIL .flexbox > img 5 assert_equals:
    15 <img src="support/solidblue.png" style="min-width: 34px" data-expected-width="40" data-expected-height="40">
    16 height expected 40 but got 34
    17 FAIL .flexbox > img 6 assert_equals:
    18 <img src="support/solidblue.png" style="min-height: 34px" data-expected-width="40" data-expected-height="40">
    19 height expected 40 but got 34
    20 FAIL .flexbox > img 7 assert_equals:
    21 <img src="support/solidblue.png" style="min-width: 30px;
    22                                               min-height: 34px" data-expected-width="40" data-expected-height="40">
    23 height expected 40 but got 34
    24 FAIL .flexbox > img 8 assert_equals:
    25 <img src="support/solidblue.png" style="min-width: 34px;
    26                                               min-height: 30px" data-expected-width="40" data-expected-height="40">
    27 height expected 40 but got 34
     12PASS .flexbox > img 5
     13PASS .flexbox > img 6
     14PASS .flexbox > img 7
     15PASS .flexbox > img 8
    2816PASS .flexbox > img 9
    2917PASS .flexbox > img 10
  • trunk/Source/WebCore/ChangeLog

    r273071 r273072  
     12021-02-15  Sergio Villar Senin  <svillar@igalia.com>
     2
     3        [css-flex] Implement section 9.8 Definite and Indefinite Sizes case 1
     4        https://bugs.webkit.org/show_bug.cgi?id=219538
     5        <rdar://problem/72136484>
     6
     7        Reviewed by Manuel Rego Casasnovas.
     8
     9        If a single-line flex container has a definite cross size, the automatic preferred outer cross size
     10        of any stretched flex items is the flex container's inner cross size (clamped to the flex item's
     11        min and max cross size) and is considered definite. Before that we were considering all automatic
     12        sizes as indefinite (see https://drafts.csswg.org/css-flexbox/#definite-sizes).
     13
     14        This patch does not consider all the cases where the container cross size is definite but just when
     15        that size is fixed. Support for additional cases should be added in followup patches.
     16
     17        This change unveiled an implementation mistake when computing content sizes for the min-size:auto case.
     18        In those cases we were always calling computeMainAxisExtentForChild() but that does not take into
     19        account the aspect ratio, that's why we added an additional code path which computes the content
     20        size using computeMainSizeFromAspectRatioUsing() instead.
     21
     22        This fixes 8 full tests plus 24 subtests in some other flexbox aspect ratio tests from the WPT suite.
     23
     24        * rendering/RenderFlexibleBox.cpp:
     25        (WebCore::RenderFlexibleBox::useChildAspectRatio const): Use ternary operator to simplify code.
     26        (WebCore::RenderFlexibleBox::computeMainSizeFromAspectRatioUsing const): Resolve child size to container's
     27        size if childCrossSizeShouldUseContainerCrossSize().
     28        (WebCore::RenderFlexibleBox::childCrossSizeShouldUseContainerCrossSize const): New method implementing
     29        section 9.8.1 of the specs.
     30        (WebCore::RenderFlexibleBox::childCrossSizeIsDefinite const):
     31        (WebCore::RenderFlexibleBox::computeInnerFlexBaseSizeForChild): Use aspect ratio to compute cross size
     32        also if childCrossSizeShouldUseContainerCrossSize().
     33        (WebCore::RenderFlexibleBox::adjustChildSizeForMinAndMax): Use aspect ratio specific code to compute
     34        content size if aspect ratio should be used for child.
     35        (WebCore::RenderFlexibleBox::adjustChildSizeForAspectRatioCrossAxisMinAndMax):
     36        * rendering/RenderFlexibleBox.h:
     37
    1382021-02-18  Youenn Fablet  <youenn@apple.com>
    239
  • trunk/Source/WebCore/rendering/RenderFlexibleBox.cpp

    r272846 r273072  
    747747        return false;
    748748    }
    749     Length crossSize;
    750     if (isHorizontalFlow())
    751         crossSize = child.style().height();
    752     else
    753         crossSize = child.style().width();
    754     return childCrossSizeIsDefinite(child, crossSize);
     749    return childCrossSizeIsDefinite(child, isHorizontalFlow() ? child.style().height() : child.style().width());
    755750}
    756751
     
    775770    if (crossSizeLength.isFixed())
    776771        crossSize = adjustForBoxSizing(child, crossSizeLength);
    777     else {
     772    else if (crossSizeLength.isAuto()) {
     773        ASSERT(childCrossSizeShouldUseContainerCrossSize(child));
     774        auto containerCrossSizeLength = isHorizontalFlow() ? style().height() : style().width();
     775        // Keep this sync'ed with childCrossSizeShouldUseContainerCrossSize().
     776        ASSERT(containerCrossSizeLength.isFixed());
     777        crossSize = valueForLength(containerCrossSizeLength, -1_lu);
     778    } else {
    778779        ASSERT(crossSizeLength.isPercentOrCalculated());
    779780        crossSize = mainAxisIsChildInlineAxis(child) ? child.computePercentageLogicalHeight(crossSizeLength) : adjustBorderBoxLogicalWidthForBoxSizing(valueForLength(crossSizeLength, contentWidth()), crossSizeLength.type());
     
    823824}
    824825
     826bool RenderFlexibleBox::childCrossSizeShouldUseContainerCrossSize(const RenderBox& child) const
     827{
     828    if (!child.hasAspectRatio() || !child.intrinsicSize().height())
     829        return false;
     830
     831    // 9.8 https://drafts.csswg.org/css-flexbox/#definite-sizes
     832    // 1. If a single-line flex container has a definite cross size, the automatic preferred outer cross size of any
     833    // stretched flex items is the flex container's inner cross size (clamped to the flex item's min and max cross size)
     834    // and is considered definite.
     835    if (!isMultiline() && alignmentForChild(child) == ItemPosition::Stretch && !hasAutoMarginsInCrossAxis(child)) {
     836        // This must be kept in sync with computeMainSizeFromAspectRatioUsing().
     837        // FIXME: so far we're only considered fixed sizes but we should extend it to other definite sizes.
     838        auto& crossSize = isHorizontalFlow() ? style().height() : style().width();
     839        return crossSize.isFixed();
     840    }
     841    return false;
     842}
     843
    825844bool RenderFlexibleBox::childCrossSizeIsDefinite(const RenderBox& child, const Length& length) const
    826845{
    827846    if (length.isAuto())
    828847        return false;
     848
    829849    if (length.isPercentOrCalculated()) {
    830850        if (!mainAxisIsChildInlineAxis(child) || m_hasDefiniteHeight == SizeDefiniteness::Definite)
     
    873893        return std::max(0_lu, computeMainAxisExtentForChild(child, MainOrPreferredSize, flexBasis).value());
    874894
    875     if (useChildAspectRatio(child)) {
     895    if (useChildAspectRatio(child) || childCrossSizeShouldUseContainerCrossSize(child)) {
    876896        const Length& crossSizeLength = isHorizontalFlow() ? child.style().height() : child.style().width();
    877897        return adjustChildSizeForAspectRatioCrossAxisMinAndMax(child, computeMainSizeFromAspectRatioUsing(child, crossSizeLength));
     
    11511171        // FIXME: If the min value is expected to be valid here, we need to come up with a non optional version of computeMainAxisExtentForChild and
    11521172        // ensure it's valid through the virtual calls of computeIntrinsicLogicalContentHeightUsing.
    1153         LayoutUnit contentSize = computeMainAxisExtentForChild(child, MinSize, Length(LengthType::MinContent)).valueOr(0);
     1173        LayoutUnit contentSize;
     1174        Length childCrossSizeLength = isHorizontalFlow() ? child.style().height() : child.style().width();
     1175        if (useChildAspectRatio(child))
     1176            contentSize = computeMainSizeFromAspectRatioUsing(child, childCrossSizeLength);
     1177        else
     1178            contentSize = computeMainAxisExtentForChild(child, MinSize, Length(LengthType::MinContent)).valueOr(0);
     1179        if (child.hasAspectRatio() && child.intrinsicSize().height())
     1180            contentSize = adjustChildSizeForAspectRatioCrossAxisMinAndMax(child, contentSize);
    11541181        ASSERT(contentSize >= 0);
    1155         if (child.hasAspectRatio() && child.intrinsicSize().height() > 0)
    1156             contentSize = adjustChildSizeForAspectRatioCrossAxisMinAndMax(child, contentSize);
    11571182        contentSize = std::min(contentSize, maxExtent.valueOr(contentSize));
    11581183       
     
    11651190        }
    11661191
    1167         if (useChildAspectRatio(child)) {
    1168             Length crossSizeLength = isHorizontalFlow() ? child.style().height() : child.style().width();
    1169             Optional<LayoutUnit> transferredSize = computeMainSizeFromAspectRatioUsing(child, crossSizeLength);
     1192        if (useChildAspectRatio(child) || childCrossSizeShouldUseContainerCrossSize(child)) {
     1193            Optional<LayoutUnit> transferredSize = computeMainSizeFromAspectRatioUsing(child, childCrossSizeLength);
    11701194            if (transferredSize) {
    11711195                transferredSize = adjustChildSizeForAspectRatioCrossAxisMinAndMax(child, transferredSize.value());
     
    11731197            }
    11741198        }
    1175        
     1199
    11761200        return std::max(childSize, contentSize);
    11771201    }
     
    12221246    Length crossMin = isHorizontalFlow() ? child.style().minHeight() : child.style().minWidth();
    12231247    Length crossMax = isHorizontalFlow() ? child.style().maxHeight() : child.style().maxWidth();
    1224    
     1248
    12251249    if (childCrossSizeIsDefinite(child, crossMax)) {
    12261250        LayoutUnit maxValue = computeMainSizeFromAspectRatioUsing(child, crossMax);
    12271251        childSize = std::min(maxValue, childSize);
    12281252    }
    1229    
     1253
    12301254    if (childCrossSizeIsDefinite(child, crossMin)) {
    12311255        LayoutUnit minValue = computeMainSizeFromAspectRatioUsing(child, crossMin);
  • trunk/Source/WebCore/rendering/RenderFlexibleBox.h

    r272054 r273072  
    142142    LayoutPoint flowAwareLocationForChild(const RenderBox& child) const;
    143143    bool useChildAspectRatio(const RenderBox& child) const;
     144    bool childCrossSizeShouldUseContainerCrossSize(const RenderBox& child) const;
    144145    LayoutUnit computeMainSizeFromAspectRatioUsing(const RenderBox& child, Length crossSizeLength) const;
    145146    void setFlowAwareLocationForChild(RenderBox& child, const LayoutPoint&);
Note: See TracChangeset for help on using the changeset viewer.