Changeset 214830 in webkit


Ignore:
Timestamp:
Apr 3, 2017 12:08:07 PM (7 years ago)
Author:
Antti Koivisto
Message:

REGRESSION (r207669): FileMaker Pro Help pages do not render correctly
https://bugs.webkit.org/show_bug.cgi?id=170402
<rdar://problem/31004344>

Reviewed by Simon Fraser.

Source/WebCore:

If a new stylesheet load is started from the load event the document.styleSheets does not
always reflect the already loaded stylesheets.

Test: fast/css/document-stylesheets-dynamic.html

  • style/StyleScope.cpp:

(WebCore::Style::Scope::updateActiveStyleSheets):

Remove an old optimization where we would not update active stylesheets if there were pending
(head) stylesheet loads and they had not been updated already.
This is probably not a valuable optimization anymore with the new lazy stylesheet update strategy.

  • style/StyleScope.h:

LayoutTests:

  • fast/css/document-stylesheets-dynamic-expected.html: Added.
  • fast/css/document-stylesheets-dynamic.html: Added.
Location:
trunk
Files:
2 added
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r214820 r214830  
     12017-04-03  Antti Koivisto  <antti@apple.com>
     2
     3        REGRESSION (r207669): FileMaker Pro Help pages do not render correctly
     4        https://bugs.webkit.org/show_bug.cgi?id=170402
     5        <rdar://problem/31004344>
     6
     7        Reviewed by Simon Fraser.
     8
     9        * fast/css/document-stylesheets-dynamic-expected.html: Added.
     10        * fast/css/document-stylesheets-dynamic.html: Added.
     11
    1122017-04-03  Jeremy Jones  <jeremyj@apple.com>
    213
  • trunk/Source/WebCore/ChangeLog

    r214829 r214830  
     12017-04-03  Antti Koivisto  <antti@apple.com>
     2
     3        REGRESSION (r207669): FileMaker Pro Help pages do not render correctly
     4        https://bugs.webkit.org/show_bug.cgi?id=170402
     5        <rdar://problem/31004344>
     6
     7        Reviewed by Simon Fraser.
     8
     9        If a new stylesheet load is started from the load event the document.styleSheets does not
     10        always reflect the already loaded stylesheets.
     11
     12        Test: fast/css/document-stylesheets-dynamic.html
     13
     14        * style/StyleScope.cpp:
     15        (WebCore::Style::Scope::updateActiveStyleSheets):
     16
     17            Remove an old optimization where we would not update active stylesheets if there were pending
     18            (head) stylesheet loads and they had not been updated already.
     19            This is probably not a valuable optimization anymore with the new lazy stylesheet update strategy.
     20
     21        * style/StyleScope.h:
     22
    1232017-04-03  Anders Carlsson  <andersca@apple.com>
    224
  • trunk/Source/WebCore/style/StyleScope.cpp

    r214435 r214830  
    444444    }
    445445
    446     // Don't bother updating, since we haven't loaded all our style info yet
    447     // and haven't calculated the style resolver for the first time.
    448     if (!m_shadowRoot && !m_didUpdateActiveStyleSheets && hasPendingSheetsBeforeBody()) {
    449         clearResolver();
    450         return;
    451     }
    452 
    453     m_didUpdateActiveStyleSheets = true;
    454 
    455446    Vector<RefPtr<StyleSheet>> activeStyleSheets;
    456447    collectActiveStyleSheets(activeStyleSheets);
  • trunk/Source/WebCore/style/StyleScope.h

    r214378 r214830  
    164164    HashSet<const Element*> m_elementsInBodyWithPendingSheets;
    165165
    166     bool m_didUpdateActiveStyleSheets { false };
    167 
    168166    std::optional<UpdateType> m_pendingUpdate;
    169167    bool m_hasDescendantWithPendingUpdate { false };
Note: See TracChangeset for help on using the changeset viewer.