Changeset 198553 in webkit
- Timestamp:
- Mar 22, 2016 2:31:16 PM (8 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r198551 r198553 1 2016-03-22 Antti Koivisto <antti@apple.com> 2 3 Non-const DocumentRuleSets::features() does not check default style version 4 https://bugs.webkit.org/show_bug.cgi?id=155766 5 6 Reviewed by Andreas Kling. 7 8 This may leave it out of date when the default stylesheet expands. 9 10 No test, don't know how to hit this with current codebase. With some further optimizations 11 it starts affecting some tests involving UA media control stylesheets. 12 13 * css/DocumentRuleSets.h: 14 (WebCore::DocumentRuleSets::mutableFeatures): 15 16 Check the default style version number in non-const case too. 17 1 18 2016-03-22 Daniel Bates <dabates@apple.com> 2 19 -
trunk/Source/WebCore/css/DocumentRuleSets.h
r196629 r198553 47 47 RuleSet* authorStyle() const { return m_authorStyle.get(); } 48 48 RuleSet* userStyle() const { return m_userStyle.get(); } 49 RuleFeatureSet& features() { return m_features; }50 49 const RuleFeatureSet& features() const; 51 50 RuleSet* sibling() const { return m_siblingRuleSet.get(); } … … 62 61 void resetAuthorStyle(); 63 62 void appendAuthorStyleSheets(const Vector<RefPtr<CSSStyleSheet>>&, MediaQueryEvaluator*, InspectorCSSOMWrappers&, StyleResolver*); 63 64 RuleFeatureSet& mutableFeatures(); 64 65 65 66 private: … … 85 86 } 86 87 88 // FIXME: There should be just the const version. 89 inline RuleFeatureSet& DocumentRuleSets::mutableFeatures() 90 { 91 if (m_defaultStyleVersionOnFeatureCollection < CSSDefaultStyleSheets::defaultStyleVersion) 92 collectFeatures(); 93 return m_features; 94 } 95 87 96 } // namespace WebCore 88 97 -
trunk/Source/WebCore/css/StyleBuilderCustom.h
r196991 r198553 1346 1346 didSet = true; 1347 1347 // Register the fact that the attribute value affects the style. 1348 styleResolver.ruleSets(). features().attributeCanonicalLocalNamesInRules.add(attr.localName().impl());1349 styleResolver.ruleSets(). features().attributeLocalNamesInRules.add(attr.localName().impl());1348 styleResolver.ruleSets().mutableFeatures().attributeCanonicalLocalNamesInRules.add(attr.localName().impl()); 1349 styleResolver.ruleSets().mutableFeatures().attributeLocalNamesInRules.add(attr.localName().impl()); 1350 1350 } else if (contentValue.isCounter()) { 1351 1351 Counter* counterValue = contentValue.getCounterValue(); … … 1716 1716 1717 1717 // Register the fact that the attribute value affects the style. 1718 styleResolver.ruleSets(). features().attributeCanonicalLocalNamesInRules.add(attr.localName().impl());1719 styleResolver.ruleSets(). features().attributeLocalNamesInRules.add(attr.localName().impl());1718 styleResolver.ruleSets().mutableFeatures().attributeCanonicalLocalNamesInRules.add(attr.localName().impl()); 1719 styleResolver.ruleSets().mutableFeatures().attributeLocalNamesInRules.add(attr.localName().impl()); 1720 1720 } else 1721 1721 styleResolver.style()->setContentAltText(emptyAtom);
Note: See TracChangeset
for help on using the changeset viewer.