Changeset 230349 in webkit


Ignore:
Timestamp:
Apr 6, 2018 12:31:15 PM (6 years ago)
Author:
Alan Bujtas
Message:

Flex child does not get repainted when it is inserted back to the render tree.
https://bugs.webkit.org/show_bug.cgi?id=184361
<rdar://problem/34528716>

Reviewed by Antti Koivisto.

Source/WebCore:

As with any regular block children, we should issue full repaint for flexbox items on their
first layout (see RenderBlockFlow::layoutBlockChild()).

Test: fast/flexbox/missing-repaint-when-flext-item-never-had-layout.html

  • rendering/RenderFlexibleBox.cpp:

(WebCore::RenderFlexibleBox::layoutAndPlaceChildren):

LayoutTests:

  • fast/flexbox/missing-repaint-when-flext-item-never-had-layout-expected.txt: Added.
  • fast/flexbox/missing-repaint-when-flext-item-never-had-layout.html: Added.
Location:
trunk
Files:
2 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r230346 r230349  
     12018-04-06  Zalan Bujtas  <zalan@apple.com>
     2
     3        Flex child does not get repainted when it is inserted back to the render tree.
     4        https://bugs.webkit.org/show_bug.cgi?id=184361
     5        <rdar://problem/34528716>
     6
     7        Reviewed by Antti Koivisto.
     8
     9        * fast/flexbox/missing-repaint-when-flext-item-never-had-layout-expected.txt: Added.
     10        * fast/flexbox/missing-repaint-when-flext-item-never-had-layout.html: Added.
     11
    1122018-04-06  Daniel Bates  <dabates@apple.com>
    213
  • trunk/Source/WebCore/ChangeLog

    r230348 r230349  
     12018-04-06  Zalan Bujtas  <zalan@apple.com>
     2
     3        Flex child does not get repainted when it is inserted back to the render tree.
     4        https://bugs.webkit.org/show_bug.cgi?id=184361
     5        <rdar://problem/34528716>
     6
     7        Reviewed by Antti Koivisto.
     8
     9        As with any regular block children, we should issue full repaint for flexbox items on their
     10        first layout (see RenderBlockFlow::layoutBlockChild()).
     11
     12        Test: fast/flexbox/missing-repaint-when-flext-item-never-had-layout.html
     13
     14        * rendering/RenderFlexibleBox.cpp:
     15        (WebCore::RenderFlexibleBox::layoutAndPlaceChildren):
     16
    1172018-04-06  Ms2ger  <Ms2ger@igalia.com>
    218
  • trunk/Source/WebCore/rendering/RenderFlexibleBox.cpp

    r229531 r230349  
    15531553        const auto& flexItem = children[i];
    15541554        auto& child = flexItem.box;
     1555        bool childHadLayout = child.everHadLayout();
    15551556
    15561557        ASSERT(!flexItem.box.isOutOfFlowPositioned());
     
    15831584            m_relaidOutChildren.add(&child);
    15841585        child.layoutIfNeeded();
     1586        if (!childHadLayout && child.checkForRepaintDuringLayout()) {
     1587            child.repaint();
     1588            child.repaintOverhangingFloats(true);
     1589        }
    15851590
    15861591        updateAutoMarginsInMainAxis(child, autoMarginOffset);
Note: See TracChangeset for help on using the changeset viewer.