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

Unified Diff: Source/core/inspector/InspectorInstrumentation.cpp

Issue 898593002: DevTools: use per-LocalFrame instrumenting agents instead of per-Page ones. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: fixed assertion Created 5 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
Index: Source/core/inspector/InspectorInstrumentation.cpp
diff --git a/Source/core/inspector/InspectorInstrumentation.cpp b/Source/core/inspector/InspectorInstrumentation.cpp
index ccc9b2800731f0053f027e7a95542f28f325ab59..4029db903331a586f9b287da8479a64df5113755 100644
--- a/Source/core/inspector/InspectorInstrumentation.cpp
+++ b/Source/core/inspector/InspectorInstrumentation.cpp
@@ -195,11 +195,9 @@ InspectorTimelineAgent* retrieveTimelineAgent(const InspectorInstrumentationCook
return 0;
}
-InstrumentingAgents* instrumentingAgentsFor(Page* page)
+InstrumentingAgents* instrumentingAgentsFor(LocalFrame* frame)
{
- if (!page)
- return 0;
- return instrumentationForPage(page);
+ return frame ? frame->instrumentingAgents() : nullptr;
}
InstrumentingAgents* instrumentingAgentsFor(EventTarget* eventTarget)
@@ -221,11 +219,6 @@ InstrumentingAgents* instrumentingAgentsFor(WorkerGlobalScope* workerGlobalScope
return instrumentationForWorkerGlobalScope(workerGlobalScope);
}
-InstrumentingAgents* instrumentingAgentsFor(FrameHost* host)
-{
- return instrumentationForPage(&host->page());
-}
-
InstrumentingAgents* instrumentingAgentsForNonDocumentContext(ExecutionContext* context)
{
if (context->isWorkerGlobalScope())
@@ -254,12 +247,6 @@ const char PageId[] = "pageId";
const char CallbackName[] = "callbackName";
};
-InstrumentingAgents* instrumentationForPage(Page* page)
-{
- ASSERT(isMainThread());
- return page->inspectorController().m_instrumentingAgents.get();
-}
-
InstrumentingAgents* instrumentationForWorkerGlobalScope(WorkerGlobalScope* workerGlobalScope)
{
if (WorkerInspectorController* controller = workerGlobalScope->workerInspectorController())
« no previous file with comments | « Source/core/inspector/InspectorInstrumentation.h ('k') | Source/core/inspector/InspectorInstrumentation.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698