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

Unified Diff: Source/core/page/Page.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/page/Page.h ('k') | Source/core/platform/LifecycleContext.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/page/Page.cpp
diff --git a/Source/core/page/Page.cpp b/Source/core/page/Page.cpp
index 0239888a77f891ac72d044ea40e25b210e001340..ea2f822482f35ab9b44a101fa69f87a4ffe9e325 100644
--- a/Source/core/page/Page.cpp
+++ b/Source/core/page/Page.cpp
@@ -559,7 +559,7 @@ void Page::setVisibilityState(PageVisibilityState visibilityState, bool isInitia
setTimerAlignmentInterval(DOMTimer::visiblePageAlignmentInterval());
if (!isInitialState)
- lifecycleNotifier()->notifyPageVisibilityChanged();
+ lifecycleNotifier().notifyPageVisibilityChanged();
if (!isInitialState && m_mainFrame)
m_mainFrame->dispatchVisibilityStateChangeEvent();
@@ -589,14 +589,14 @@ void Page::multisamplingChanged()
void Page::didCommitLoad(Frame* frame)
{
- lifecycleNotifier()->notifyDidCommitLoad(frame);
+ lifecycleNotifier().notifyDidCommitLoad(frame);
if (m_mainFrame == frame)
useCounter().didCommitLoad();
}
-PageLifecycleNotifier* Page::lifecycleNotifier()
+PageLifecycleNotifier& Page::lifecycleNotifier()
{
- return static_cast<PageLifecycleNotifier*>(LifecycleContext::lifecycleNotifier());
+ return static_cast<PageLifecycleNotifier&>(LifecycleContext::lifecycleNotifier());
}
PassOwnPtr<LifecycleNotifier<Page> > Page::createLifecycleNotifier()
« no previous file with comments | « Source/core/page/Page.h ('k') | Source/core/platform/LifecycleContext.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698