Changeset 262061 in webkit


Ignore:
Timestamp:
May 22, 2020 9:45:36 AM (4 years ago)
Author:
Oriol Brufau
Message:

Don't put out-of-flow boxes in anonymous flex/grid items
https://bugs.webkit.org/show_bug.cgi?id=205386

Reviewed by Manuel Rego Casasnovas.

Source/WebCore:

A single anonymous flex/grid item should just contain a contiguous
sequence of text runs.

This patch is based on https://crrev.com/533825 from Chromium.

Tests: imported/w3c/web-platform-tests/css/css-flexbox/anonymous-flex-item-004.html

imported/w3c/web-platform-tests/css/css-grid/grid-items/anonymous-grid-item-001.html

  • rendering/updating/RenderTreeBuilderBlock.cpp:

(WebCore::RenderTreeBuilder::Block::attachIgnoringContinuation):

LayoutTests:

Expect tests to pass.

Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r262060 r262061  
     12020-05-22  Oriol Brufau  <obrufau@igalia.com>
     2
     3        Don't put out-of-flow boxes in anonymous flex/grid items
     4        https://bugs.webkit.org/show_bug.cgi?id=205386
     5
     6        Reviewed by Manuel Rego Casasnovas.
     7
     8        Expect tests to pass.
     9
     10        * TestExpectations:
     11
    1122020-05-22  Myles C. Maxfield  <mmaxfield@apple.com>
    213
  • trunk/LayoutTests/TestExpectations

    r262056 r262061  
    10601060imported/w3c/web-platform-tests/css/css-grid/abspos/orthogonal-positioned-grid-descendants-015.html [ Pass Failure ]
    10611061webkit.org/b/191367 imported/w3c/web-platform-tests/css/css-grid/grid-model/grid-container-ignores-first-letter-002.html [ ImageOnlyFailure ]
    1062 webkit.org/b/191460 imported/w3c/web-platform-tests/css/css-grid/grid-items/anonymous-grid-item-001.html [ Skip ]
    10631062webkit.org/b/191461 imported/w3c/web-platform-tests/css/css-grid/grid-items/percentage-size-subitems-001.html [ ImageOnlyFailure ]
    10641063webkit.org/b/191462 imported/w3c/web-platform-tests/css/css-grid/grid-items/percentage-size-replaced-subitems-001.html [ ImageOnlyFailure ]
     
    42404239webkit.org/b/210093 imported/w3c/web-platform-tests/css/css-flexbox/select-element-zero-height-002.html [ ImageOnlyFailure ]
    42414240webkit.org/b/210102 imported/w3c/web-platform-tests/css/css-flexbox/table-as-item-auto-min-width.html [ ImageOnlyFailure ]
    4242 webkit.org/b/210144 imported/w3c/web-platform-tests/css/css-flexbox/anonymous-flex-item-004.html [ ImageOnlyFailure ]
    42434241webkit.org/b/210144 imported/w3c/web-platform-tests/css/css-flexbox/anonymous-flex-item-005.html [ ImageOnlyFailure ]
    42444242webkit.org/b/210465 imported/w3c/web-platform-tests/css/css-flexbox/flex-wrap-002.html [ ImageOnlyFailure ]
  • trunk/Source/WebCore/ChangeLog

    r262051 r262061  
     12020-05-22  Oriol Brufau  <obrufau@igalia.com>
     2
     3        Don't put out-of-flow boxes in anonymous flex/grid items
     4        https://bugs.webkit.org/show_bug.cgi?id=205386
     5
     6        Reviewed by Manuel Rego Casasnovas.
     7
     8        A single anonymous flex/grid item should just contain a contiguous
     9        sequence of text runs.
     10
     11        This patch is based on https://crrev.com/533825 from Chromium.
     12
     13        Tests: imported/w3c/web-platform-tests/css/css-flexbox/anonymous-flex-item-004.html
     14               imported/w3c/web-platform-tests/css/css-grid/grid-items/anonymous-grid-item-001.html
     15
     16        * rendering/updating/RenderTreeBuilderBlock.cpp:
     17        (WebCore::RenderTreeBuilder::Block::attachIgnoringContinuation):
     18
    1192020-05-22  Tim Horton  <timothy_horton@apple.com>
    220
  • trunk/Source/WebCore/rendering/updating/RenderTreeBuilderBlock.cpp

    r258455 r262061  
    223223            ASSERT(beforeChild->parent() == &parent);
    224224        }
    225     } else if (!parent.childrenInline() && (child->isFloatingOrOutOfFlowPositioned() || child->isInline())) {
     225    } else if (!parent.childrenInline() && ((child->isFloatingOrOutOfFlowPositioned() && !parent.isFlexibleBox() && !parent.isRenderGrid()) || child->isInline())) {
    226226        // If we're inserting an inline child but all of our children are blocks, then we have to make sure
    227227        // it is put into an anomyous block box. We try to use an existing anonymous box if possible, otherwise
Note: See TracChangeset for help on using the changeset viewer.