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

Unified Diff: Source/core/dom/Document.cpp

Issue 38143002: Have LifecycleContext::lifecycleNotifier() return a reference (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 7 years, 2 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.h ('k') | Source/core/dom/ExecutionContext.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/Document.cpp
diff --git a/Source/core/dom/Document.cpp b/Source/core/dom/Document.cpp
index eddd078839e5698fb2ef682be4d455bfd8d242d1..37e740c9c8cfcc4ce020062b718752e0a686d15a 100644
--- a/Source/core/dom/Document.cpp
+++ b/Source/core/dom/Document.cpp
@@ -621,7 +621,7 @@ void Document::dispose()
accessSVGExtensions()->pauseAnimations();
m_lifecyle.advanceTo(DocumentLifecycle::Disposed);
- lifecycleNotifier()->notifyDocumentWasDisposed();
+ lifecycleNotifier().notifyDocumentWasDisposed();
}
SelectorQueryCache& Document::selectorQueryCache()
@@ -2049,7 +2049,7 @@ void Document::detach(const AttachContext& context)
if (m_mediaQueryMatcher)
m_mediaQueryMatcher->documentDestroyed();
- lifecycleNotifier()->notifyDocumentWasDetached();
+ lifecycleNotifier().notifyDocumentWasDetached();
m_lifecyle.advanceTo(DocumentLifecycle::Stopped);
}
@@ -5332,9 +5332,9 @@ PassOwnPtr<LifecycleNotifier<ExecutionContext> > Document::createLifecycleNotifi
return DocumentLifecycleNotifier::create(this);
}
-DocumentLifecycleNotifier* Document::lifecycleNotifier()
+DocumentLifecycleNotifier& Document::lifecycleNotifier()
{
- return static_cast<DocumentLifecycleNotifier*>(ExecutionContext::lifecycleNotifier());
+ return static_cast<DocumentLifecycleNotifier&>(ExecutionContext::lifecycleNotifier());
}
void Document::removedStyleSheet(StyleSheet* sheet, RecalcStyleTime when, StyleResolverUpdateMode updateMode)
« no previous file with comments | « Source/core/dom/Document.h ('k') | Source/core/dom/ExecutionContext.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698