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

Unified Diff: Source/core/dom/DocumentStyleSheetCollection.h

Issue 14604003: When there are no more stylesheets schedule the recalc async (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Refactor based on review Created 7 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: Source/core/dom/DocumentStyleSheetCollection.h
diff --git a/Source/core/dom/DocumentStyleSheetCollection.h b/Source/core/dom/DocumentStyleSheetCollection.h
index 51997fa8e11097c8a34fbd4009f631c14395da60..337df669d0d0d4f01a0fa6deca18b8d268778632 100644
--- a/Source/core/dom/DocumentStyleSheetCollection.h
+++ b/Source/core/dom/DocumentStyleSheetCollection.h
@@ -28,6 +28,7 @@
#ifndef DocumentStyleSheetCollection_h
#define DocumentStyleSheetCollection_h
+#include "Document.h"
#include <wtf/FastAllocBase.h>
#include <wtf/ListHashSet.h>
#include <wtf/RefPtr.h>
@@ -73,8 +74,7 @@ public:
bool needsUpdateActiveStylesheetsOnStyleRecalc() const { return m_needsUpdateActiveStylesheetsOnStyleRecalc; }
- enum UpdateFlag { FullUpdate, OptimizedUpdate };
- bool updateActiveStyleSheets(UpdateFlag);
+ bool updateActiveStyleSheets(StyleResolverUpdateMode);
String preferredStylesheetSetName() const { return m_preferredStylesheetSetName; }
String selectedStylesheetSetName() const { return m_selectedStylesheetSetName; }
@@ -109,12 +109,9 @@ private:
DocumentStyleSheetCollection(Document*);
void collectActiveStyleSheets(Vector<RefPtr<StyleSheet> >&);
- enum StyleResolverUpdateType {
- Reconstruct,
- Reset,
- Additive
- };
- void analyzeStyleSheetChange(UpdateFlag, const Vector<RefPtr<CSSStyleSheet> >& newStylesheets, StyleResolverUpdateType&, bool& requiresFullStyleRecalc);
+
+ enum UpdateAction { Reconstruct, Reset, Append };
+ UpdateAction analyzeStyleSheetChange(StyleResolverUpdateMode, const Vector<RefPtr<CSSStyleSheet> >& newStylesheets, bool& requiresFullStyleRecalc);
Document* m_document;

Powered by Google App Engine
This is Rietveld 408576698