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

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

Issue 150423004: Move Document::m_inStyleRecalc into DocumentLifecycle (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rename state Created 6 years, 11 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
« no previous file with comments | « Source/core/dom/Document.cpp ('k') | Source/core/dom/DocumentLifecycle.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/DocumentLifecycle.h
diff --git a/Source/core/dom/DocumentLifecycle.h b/Source/core/dom/DocumentLifecycle.h
index c3f919635e833a43521a5a7e401602671935c4f6..22d66867cb20d40480654ac1506bef184ced68d9 100644
--- a/Source/core/dom/DocumentLifecycle.h
+++ b/Source/core/dom/DocumentLifecycle.h
@@ -41,7 +41,13 @@ public:
enum State {
Uninitialized,
Inactive,
- Active,
+
+ // When the document is active, it traverses these states.
+ Clean,
+ InStyleRecalc,
+
+ // Once the document starts shuting down, we cannot return
+ // to the style/layout/rendering states.
Stopping,
Stopped,
Disposed,
@@ -50,6 +56,7 @@ public:
DocumentLifecycle();
~DocumentLifecycle();
+ bool isActive() const { return m_state > Inactive && m_state < Stopping; }
State state() const { return m_state; }
void advanceTo(State);
« no previous file with comments | « Source/core/dom/Document.cpp ('k') | Source/core/dom/DocumentLifecycle.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698