Changeset 254371 in webkit


Ignore:
Timestamp:
Jan 10, 2020 3:13:34 PM (4 years ago)
Author:
Antti Koivisto
Message:

[LFC][Integration] Fix accessibility/deleting-iframe-destroys-axcache.html and accessibility/div-within-anchors-causes-crash.html
https://bugs.webkit.org/show_bug.cgi?id=206072

Reviewed by Zalan Bujtas.

  • layout/integration/LayoutIntegrationLineLayout.cpp:

(WebCore::LayoutIntegration::LineLayout::lineCount const):

We may have a line layout with 0 runs but 1 line. In these cases line count must return 0
to match other systems.

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r254356 r254371  
     12020-01-10  Antti Koivisto  <antti@apple.com>
     2
     3        [LFC][Integration] Fix accessibility/deleting-iframe-destroys-axcache.html and accessibility/div-within-anchors-causes-crash.html
     4        https://bugs.webkit.org/show_bug.cgi?id=206072
     5
     6        Reviewed by Zalan Bujtas.
     7
     8        * layout/integration/LayoutIntegrationLineLayout.cpp:
     9        (WebCore::LayoutIntegration::LineLayout::lineCount const):
     10
     11        We may have a line layout with 0 runs but 1 line. In these cases line count must return 0
     12        to match other systems.
     13
    1142020-01-10  Jiewen Tan  <jiewen_tan@apple.com>
    215
  • trunk/Source/WebCore/layout/integration/LayoutIntegrationLineLayout.cpp

    r253999 r254371  
    106106{
    107107    auto* inlineContent = displayInlineContent();
    108     return inlineContent ? inlineContent->lineBoxes.size() : 0;
     108    if (!inlineContent)
     109        return 0;
     110    if (inlineContent->runs.isEmpty())
     111        return 0;
     112    return inlineContent->lineBoxes.size();
    109113}
    110114
Note: See TracChangeset for help on using the changeset viewer.