Index: Source/core/css/RuleFeature.h |
diff --git a/Source/core/css/RuleFeature.h b/Source/core/css/RuleFeature.h |
index 7541f59038c4d9d0bce74e11618e81af353f31af..09b7733d289ae3efc257a42bb7894ffecd469625 100644 |
--- a/Source/core/css/RuleFeature.h |
+++ b/Source/core/css/RuleFeature.h |
@@ -25,7 +25,6 @@ |
#include "core/CoreExport.h" |
#include "core/css/CSSSelector.h" |
#include "core/css/invalidation/DescendantInvalidationSet.h" |
-#include "core/css/invalidation/StyleInvalidator.h" |
#include "wtf/Forward.h" |
#include "wtf/HashSet.h" |
#include "wtf/text/AtomicStringHash.h" |
@@ -49,6 +48,8 @@ public: |
bool hasDocumentSecurityOrigin; |
}; |
+using InvalidationSetVector = WillBeHeapVector<RefPtrWillBeMember<DescendantInvalidationSet>, 8>; |
+ |
class CORE_EXPORT RuleFeatureSet { |
DISALLOW_ALLOCATION(); |
public: |
@@ -82,19 +83,16 @@ public: |
bool hasSelectorForId(const AtomicString& idValue) const { return m_idInvalidationSets.contains(idValue); } |
bool hasSelectorForPseudoType(CSSSelector::PseudoType pseudo) const { return m_pseudoInvalidationSets.contains(pseudo); } |
- void scheduleStyleInvalidationForClassChange(const SpaceSplitString& changedClasses, Element&); |
- void scheduleStyleInvalidationForClassChange(const SpaceSplitString& oldClasses, const SpaceSplitString& newClasses, Element&); |
- void scheduleStyleInvalidationForAttributeChange(const QualifiedName& attributeName, Element&); |
- void scheduleStyleInvalidationForIdChange(const AtomicString& oldId, const AtomicString& newId, Element&); |
- void scheduleStyleInvalidationForPseudoChange(CSSSelector::PseudoType, Element&); |
+ void collectInvalidationSetsForClass(InvalidationSetVector&, Element&, const AtomicString& className) const; |
+ void collectInvalidationSetsForId(InvalidationSetVector&, Element&, const AtomicString& id) const; |
+ void collectInvalidationSetsForAttribute(InvalidationSetVector&, Element&, const QualifiedName& attributeName) const; |
+ void collectInvalidationSetsForPseudoClass(InvalidationSetVector&, Element&, CSSSelector::PseudoType) const; |
bool hasIdsInSelectors() const |
{ |
return m_idInvalidationSets.size() > 0; |
} |
- StyleInvalidator& styleInvalidator(); |
- |
DECLARE_TRACE(); |
WillBeHeapVector<RuleFeature> siblingRules; |
@@ -104,8 +102,8 @@ protected: |
DescendantInvalidationSet* invalidationSetForSelector(const CSSSelector&); |
private: |
- typedef WillBeHeapHashMap<AtomicString, RefPtrWillBeMember<DescendantInvalidationSet>> InvalidationSetMap; |
- typedef WillBeHeapHashMap<CSSSelector::PseudoType, RefPtrWillBeMember<DescendantInvalidationSet>, WTF::IntHash<unsigned>, WTF::UnsignedWithZeroKeyHashTraits<unsigned>> PseudoTypeInvalidationSetMap; |
+ using InvalidationSetMap = WillBeHeapHashMap<AtomicString, RefPtrWillBeMember<DescendantInvalidationSet>>; |
+ using PseudoTypeInvalidationSetMap = WillBeHeapHashMap<CSSSelector::PseudoType, RefPtrWillBeMember<DescendantInvalidationSet>, WTF::IntHash<unsigned>, WTF::UnsignedWithZeroKeyHashTraits<unsigned>>; |
struct FeatureMetadata { |
FeatureMetadata() |
@@ -173,7 +171,6 @@ private: |
InvalidationSetMap m_attributeInvalidationSets; |
InvalidationSetMap m_idInvalidationSets; |
PseudoTypeInvalidationSetMap m_pseudoInvalidationSets; |
- StyleInvalidator m_styleInvalidator; |
}; |
} // namespace blink |