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

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

Issue 181703004: Have Document::timing() / Document::contextFeatures() return a reference (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 10 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 | « no previous file | Source/core/dom/Document.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/ContextFeatures.cpp
diff --git a/Source/core/dom/ContextFeatures.cpp b/Source/core/dom/ContextFeatures.cpp
index 547e44490fed86e60450cfd79c849cb22590ebcb..377c50e69cd79fe232d5d78ff787dffa94afaca7 100644
--- a/Source/core/dom/ContextFeatures.cpp
+++ b/Source/core/dom/ContextFeatures.cpp
@@ -54,21 +54,21 @@ bool ContextFeatures::dialogElementEnabled(Document* document)
{
if (!document)
return RuntimeEnabledFeatures::dialogElementEnabled();
- return document->contextFeatures()->isEnabled(document, DialogElement, RuntimeEnabledFeatures::dialogElementEnabled());
+ return document->contextFeatures().isEnabled(document, DialogElement, RuntimeEnabledFeatures::dialogElementEnabled());
}
bool ContextFeatures::styleScopedEnabled(Document* document)
{
if (!document)
return RuntimeEnabledFeatures::styleScopedEnabled();
- return document->contextFeatures()->isEnabled(document, StyleScoped, RuntimeEnabledFeatures::styleScopedEnabled());
+ return document->contextFeatures().isEnabled(document, StyleScoped, RuntimeEnabledFeatures::styleScopedEnabled());
}
bool ContextFeatures::pagePopupEnabled(Document* document)
{
if (!document)
return false;
- return document->contextFeatures()->isEnabled(document, PagePopup, false);
+ return document->contextFeatures().isEnabled(document, PagePopup, false);
}
bool ContextFeatures::mutationEventsEnabled(Document* document)
@@ -76,12 +76,12 @@ bool ContextFeatures::mutationEventsEnabled(Document* document)
ASSERT(document);
if (!document)
return true;
- return document->contextFeatures()->isEnabled(document, MutationEvents, true);
+ return document->contextFeatures().isEnabled(document, MutationEvents, true);
}
bool ContextFeatures::pushStateEnabled(Document* document)
{
- return document->contextFeatures()->isEnabled(document, PushState, true);
+ return document->contextFeatures().isEnabled(document, PushState, true);
}
void provideContextFeaturesTo(Page& page, ContextFeaturesClient* client)
@@ -94,7 +94,7 @@ void provideContextFeaturesToDocumentFrom(Document& document, Page& page)
ContextFeatures* provided = static_cast<ContextFeatures*>(RefCountedSupplement<Page, ContextFeatures>::from(page, ContextFeatures::supplementName()));
if (!provided)
return;
- document.setContextFeatures(provided);
+ document.setContextFeatures(*provided);
}
}
« no previous file with comments | « no previous file | Source/core/dom/Document.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698