Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(274)

Unified Diff: third_party/WebKit/Source/core/dom/TreeScopeStyleSheetCollection.h

Issue 1913833002: Current work-in-progress crbug.com/567021 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: More assert fixes Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/dom/TreeScopeStyleSheetCollection.h
diff --git a/third_party/WebKit/Source/core/dom/TreeScopeStyleSheetCollection.h b/third_party/WebKit/Source/core/dom/TreeScopeStyleSheetCollection.h
index c551990e0d732b71a52e63b9f46a6bf9418d4596..805b0f24c62048141586613baae8efb9d83ec4da 100644
--- a/third_party/WebKit/Source/core/dom/TreeScopeStyleSheetCollection.h
+++ b/third_party/WebKit/Source/core/dom/TreeScopeStyleSheetCollection.h
@@ -29,20 +29,15 @@
#define TreeScopeStyleSheetCollection_h
#include "core/CoreExport.h"
-#include "core/dom/Document.h"
#include "core/dom/DocumentOrderedList.h"
#include "core/dom/StyleSheetCollection.h"
#include "core/dom/TreeScope.h"
-#include "wtf/HashMap.h"
-#include "wtf/ListHashSet.h"
-#include "wtf/Vector.h"
-#include "wtf/text/WTFString.h"
namespace blink {
+class CSSStyleSheet;
+class Document;
class Node;
-class StyleSheetContents;
-class StyleRuleFontFace;
class CORE_EXPORT TreeScopeStyleSheetCollection : public StyleSheetCollection {
public:
@@ -50,7 +45,7 @@ public:
void removeStyleSheetCandidateNode(Node* node) { m_styleSheetCandidateNodes.remove(node); }
bool hasStyleSheetCandidateNodes() const { return !m_styleSheetCandidateNodes.isEmpty(); }
- void clearMediaQueryRuleSetStyleSheets();
+ bool mediaQueryAffectingValueChanged();
virtual bool isShadowTreeStyleSheetCollection() const { return false; }
@@ -62,37 +57,14 @@ protected:
Document& document() const { return treeScope().document(); }
TreeScope& treeScope() const { return *m_treeScope; }
- enum StyleResolverUpdateType {
- Reconstruct,
- Reset,
- Additive
- };
-
- class StyleSheetChange {
- STACK_ALLOCATED();
- public:
- StyleResolverUpdateType styleResolverUpdateType;
- bool requiresFullStyleRecalc;
- HeapVector<Member<const StyleRuleFontFace>> fontFaceRulesToRemove;
-
- StyleSheetChange()
- : styleResolverUpdateType(Reconstruct)
- , requiresFullStyleRecalc(true) { }
- };
-
- void analyzeStyleSheetChange(StyleResolverUpdateMode, const StyleSheetCollection&, StyleSheetChange&);
-
-private:
- static StyleResolverUpdateType compareStyleSheets(const HeapVector<Member<CSSStyleSheet>>& oldStyleSheets, const HeapVector<Member<CSSStyleSheet>>& newStylesheets, HeapVector<Member<StyleSheetContents>>& addedSheets);
- bool activeLoadingStyleSheetLoaded(const HeapVector<Member<CSSStyleSheet>>& newStyleSheets);
-
- friend class TreeScopeStyleSheetCollectionTest;
+ void applyActiveStyleSheetChanges(StyleSheetCollection&);
protected:
Member<TreeScope> m_treeScope;
- bool m_hadActiveLoadingStylesheet;
-
DocumentOrderedList m_styleSheetCandidateNodes;
+
+private:
+ friend class TreeScopeStyleSheetCollectionTest;
};
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698