Index: third_party/WebKit/Source/core/dom/StyleEngine.h |
diff --git a/third_party/WebKit/Source/core/dom/StyleEngine.h b/third_party/WebKit/Source/core/dom/StyleEngine.h |
index 3e2352ea9c6fa5e631dbce08bb8cb2b1da373272..326417671aecc7e54b6c2feb911b3ef0a35b080c 100644 |
--- a/third_party/WebKit/Source/core/dom/StyleEngine.h |
+++ b/third_party/WebKit/Source/core/dom/StyleEngine.h |
@@ -100,18 +100,19 @@ class CORE_EXPORT StyleEngine final |
} |
CSSStyleSheet* inspectorStyleSheet() const { return m_inspectorStyleSheet; } |
- const HeapVector<Member<CSSStyleSheet>> activeStyleSheetsForInspector() const; |
+ const ActiveStyleSheetVector activeStyleSheetsForInspector(); |
bool needsActiveStyleUpdate() const; |
- void setNeedsActiveStyleUpdate(StyleSheet*, StyleResolverUpdateMode); |
+ void setNeedsActiveStyleUpdate(TreeScope&); |
void addStyleSheetCandidateNode(Node&); |
void removeStyleSheetCandidateNode(Node&); |
void removeStyleSheetCandidateNode(Node&, TreeScope&); |
void modifiedStyleSheetCandidateNode(Node&); |
+ void mediaQueriesChangedInScope(TreeScope&); |
void watchedSelectorsChanged(); |
void initialViewportChanged(); |
void viewportRulesChanged(); |
- void importRemoved(); |
+ void importAddedOrRemoved(); |
void injectAuthorSheet(StyleSheetContents* authorSheet); |
CSSStyleSheet& ensureInspectorStyleSheet(); |
@@ -122,18 +123,16 @@ class CORE_EXPORT StyleEngine final |
RuleSet* ruleSetForSheet(CSSStyleSheet&); |
void mediaQueryAffectingValueChanged(); |
void updateStyleSheetsInImport(DocumentStyleSheetCollector& parentCollector); |
- void updateActiveStyleSheets(StyleResolverUpdateMode); |
void updateActiveStyle(); |
void markAllTreeScopesDirty() { m_allTreeScopesDirty = true; } |
- enum ActiveSheetsUpdate { DontUpdateActiveSheets, UpdateActiveSheets }; |
String preferredStylesheetSetName() const { |
return m_preferredStylesheetSetName; |
} |
String selectedStylesheetSetName() const { |
return m_selectedStylesheetSetName; |
} |
- void setPreferredStylesheetSetNameIfNotSet(const String&, ActiveSheetsUpdate); |
+ void setPreferredStylesheetSetNameIfNotSet(const String&); |
void setSelectedStylesheetSetName(const String&); |
void setHttpDefaultStyle(const String&); |
@@ -184,20 +183,13 @@ class CORE_EXPORT StyleEngine final |
StyleResolver& ensureResolver() { |
updateActiveStyle(); |
- if (!m_resolver) { |
+ if (!m_resolver) |
createResolver(); |
- } else if (m_resolver->hasPendingAuthorStyleSheets()) { |
- m_resolver->appendPendingAuthorStyleSheets(); |
- finishAppendAuthorStyleSheets(); |
- } else if (m_globalRuleSet.isDirty()) { |
- m_globalRuleSet.update(document()); |
- } |
return *m_resolver; |
} |
bool hasResolver() const { return m_resolver; } |
void clearResolver(); |
- void clearMasterResolver(); |
StyleInvalidator& styleInvalidator() { return m_styleInvalidator; } |
bool mediaQueryAffectedByViewportChange(); |
@@ -217,8 +209,6 @@ class CORE_EXPORT StyleEngine final |
void updateGenericFontFamilySettings(); |
void didDetach(); |
- bool shouldClearResolver() const; |
- void resolverChanged(StyleResolverUpdateMode); |
CSSStyleSheet* createSheet(Element&, |
const String& text, |
@@ -299,8 +289,6 @@ class CORE_EXPORT StyleEngine final |
} |
void createResolver(); |
- void appendActiveAuthorStyleSheets(); |
- void finishAppendAuthorStyleSheets(); |
CSSStyleSheet* parseSheet(Element&, |
const String& text, |
@@ -317,7 +305,6 @@ class CORE_EXPORT StyleEngine final |
} |
void updateActiveStyleSheetsInShadow( |
- StyleResolverUpdateMode, |
TreeScope*, |
UnorderedTreeScopeSet& treeScopesRemoved); |
@@ -349,9 +336,9 @@ class CORE_EXPORT StyleEngine final |
Member<StyleRuleUsageTracker> m_tracker; |
- typedef HeapHashMap<WeakMember<TreeScope>, |
- Member<ShadowTreeStyleSheetCollection>> |
- StyleSheetCollectionMap; |
+ using StyleSheetCollectionMap = |
+ HeapHashMap<WeakMember<TreeScope>, |
+ Member<ShadowTreeStyleSheetCollection>>; |
StyleSheetCollectionMap m_styleSheetCollectionMap; |
bool m_documentScopeDirty = true; |
@@ -367,7 +354,6 @@ class CORE_EXPORT StyleEngine final |
bool m_usesRemUnits = false; |
bool m_ignorePendingStylesheets = false; |
- bool m_didCalculateResolver = false; |
Member<StyleResolver> m_resolver; |
Member<ViewportStyleResolver> m_viewportResolver; |