⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 246462 in webkit


Ignore:
Timestamp:
Jun 15, 2019, 7:13:55 AM (7 years ago)
Author:
Alan Bujtas
Message:

[LFC[MarginCollapsing] Anonymous boxes never collapse their margins with siblings.
https://bugs.webkit.org/show_bug.cgi?id=198884
<rdar://problem/51773509>

Reviewed by Antti Koivisto.

  • layout/blockformatting/BlockMarginCollapse.cpp:

(WebCore::Layout::BlockFormattingContext::MarginCollapse::marginBeforeCollapsesWithPreviousSiblingMarginAfter):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r246461 r246462  
     12019-06-15  Zalan Bujtas  <zalan@apple.com>
     2
     3        [LFC[MarginCollapsing] Anonymous boxes never collapse their margins with siblings.
     4        https://bugs.webkit.org/show_bug.cgi?id=198884
     5        <rdar://problem/51773509>
     6
     7        Reviewed by Antti Koivisto.
     8
     9        * layout/blockformatting/BlockMarginCollapse.cpp:
     10        (WebCore::Layout::BlockFormattingContext::MarginCollapse::marginBeforeCollapsesWithPreviousSiblingMarginAfter):
     11
    1122019-06-15  Zalan Bujtas  <zalan@apple.com>
    213
  • trunk/Source/WebCore/layout/blockformatting/BlockMarginCollapse.cpp

    r246461 r246462  
    159159
    160160    auto& previousInFlowSibling = *layoutBox.previousInFlowSibling();
     161    if (previousInFlowSibling.isAnonymous())
     162        return false;
     163
    161164    // Margins between a floated box and any other box do not collapse.
    162165    if (layoutBox.isFloatingPositioned() || previousInFlowSibling.isFloatingPositioned())
Note: See TracChangeset for help on using the changeset viewer.