Index: Source/core/dom/ContextLifecycleObserver.h |
diff --git a/Source/core/dom/ContextLifecycleObserver.h b/Source/core/dom/ContextLifecycleObserver.h |
index 4bf29e2970b1fefda5aa0c8c4e4c394fa79434f4..19fa6f9c7bb8b4eac6cb90a4003931aba3424f7e 100644 |
--- a/Source/core/dom/ContextLifecycleObserver.h |
+++ b/Source/core/dom/ContextLifecycleObserver.h |
@@ -31,15 +31,26 @@ |
namespace blink { |
-template<> void observeContext(ExecutionContext*, LifecycleObserver<ExecutionContext>*); |
-template<> void unobserveContext(ExecutionContext*, LifecycleObserver<ExecutionContext>*); |
+class ContextLifecycleNotifier; |
-class ContextLifecycleObserver : public LifecycleObserver<ExecutionContext> { |
+class ContextLifecycleObserver : public LifecycleObserver<ExecutionContext, ContextLifecycleObserver, ContextLifecycleNotifier> { |
public: |
- explicit ContextLifecycleObserver(ExecutionContext*, Type = GenericType); |
ExecutionContext* executionContext() const { return lifecycleContext(); } |
+ |
+ enum Type { |
+ GenericType, |
+ ActiveDOMObjectType, |
+ }; |
+ |
+ Type observerType() const { return m_observerType; } |
+ |
protected: |
+ explicit ContextLifecycleObserver(ExecutionContext*, Type = GenericType); |
+ |
virtual ~ContextLifecycleObserver(); |
+ |
+private: |
+ Type m_observerType; |
}; |
} // namespace blink |