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

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

Issue 1092123004: DevTools: remove dependency of most agents on InspectorPageAgent (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: further cuts on InspectorPageAgent inter-agents API Created 5 years, 8 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/InspectorTracingAgent.cpp
diff --git a/Source/core/inspector/InspectorTracingAgent.cpp b/Source/core/inspector/InspectorTracingAgent.cpp
index ba854522b753c9a2be5264fced3c3c157dc624cc..e2070c75609573bf6a2eba02d91ba9d04e0cf0fb 100644
--- a/Source/core/inspector/InspectorTracingAgent.cpp
+++ b/Source/core/inspector/InspectorTracingAgent.cpp
@@ -9,7 +9,6 @@
#include "core/inspector/InspectorTracingAgent.h"
#include "core/inspector/IdentifiersFactory.h"
-#include "core/inspector/InspectorPageAgent.h"
#include "core/inspector/InspectorState.h"
#include "core/inspector/InspectorTraceEvents.h"
#include "core/inspector/InspectorWorkerAgent.h"
@@ -25,19 +24,19 @@ namespace {
const char devtoolsMetadataEventCategory[] = TRACE_DISABLED_BY_DEFAULT("devtools.timeline");
}
-InspectorTracingAgent::InspectorTracingAgent(Client* client, InspectorWorkerAgent* workerAgent, InspectorPageAgent* pageAgent)
+InspectorTracingAgent::InspectorTracingAgent(LocalFrame* inspectedFrame, Client* client, InspectorWorkerAgent* workerAgent)
: InspectorBaseAgent<InspectorTracingAgent, InspectorFrontend::Tracing>("Tracing")
+ , m_inspectedFrame(inspectedFrame)
, m_layerTreeId(0)
, m_client(client)
, m_workerAgent(workerAgent)
- , m_pageAgent(pageAgent)
{
}
DEFINE_TRACE(InspectorTracingAgent)
{
+ visitor->trace(m_inspectedFrame);
visitor->trace(m_workerAgent);
- visitor->trace(m_pageAgent);
InspectorBaseAgent::trace(visitor);
}
@@ -69,7 +68,7 @@ String InspectorTracingAgent::sessionId()
void InspectorTracingAgent::emitMetadataEvents()
{
- TRACE_EVENT_INSTANT1(devtoolsMetadataEventCategory, "TracingStartedInPage", TRACE_EVENT_SCOPE_THREAD, "data", InspectorTracingStartedInFrame::data(sessionId(), m_pageAgent->inspectedFrame()));
+ TRACE_EVENT_INSTANT1(devtoolsMetadataEventCategory, "TracingStartedInPage", TRACE_EVENT_SCOPE_THREAD, "data", InspectorTracingStartedInFrame::data(sessionId(), m_inspectedFrame));
if (m_layerTreeId)
setLayerTreeId(m_layerTreeId);
m_workerAgent->setTracingSessionId(sessionId());

Powered by Google App Engine
This is Rietveld 408576698