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

Unified Diff: third_party/WebKit/Source/core/inspector/InspectorProfilerAgent.cpp

Issue 1621923002: [DevTools] Remove InspectorState. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review comments Created 4 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: third_party/WebKit/Source/core/inspector/InspectorProfilerAgent.cpp
diff --git a/third_party/WebKit/Source/core/inspector/InspectorProfilerAgent.cpp b/third_party/WebKit/Source/core/inspector/InspectorProfilerAgent.cpp
index 30537f685c2b1b70d691c4704297d37be9f8f400..14ddf4992dca5d52d6e7f219ce3dc84bc48e7d6b 100644
--- a/third_party/WebKit/Source/core/inspector/InspectorProfilerAgent.cpp
+++ b/third_party/WebKit/Source/core/inspector/InspectorProfilerAgent.cpp
@@ -32,7 +32,6 @@
#include "bindings/core/v8/ScriptCallStackFactory.h"
#include "bindings/core/v8/V8Binding.h"
#include "core/frame/UseCounter.h"
-#include "core/inspector/InspectorState.h"
#include "core/inspector/InstrumentingAgents.h"
#include "core/inspector/ScriptCallStack.h"
#include "core/inspector/v8/V8ProfilerAgent.h"
@@ -60,8 +59,9 @@ InspectorProfilerAgent::~InspectorProfilerAgent()
}
// InspectorBaseAgent overrides.
-void InspectorProfilerAgent::init()
+void InspectorProfilerAgent::setState(PassRefPtr<JSONObject> state)
{
+ InspectorBaseAgent::setState(state);
m_v8ProfilerAgent->setInspectorState(m_state);
}
@@ -79,7 +79,7 @@ void InspectorProfilerAgent::clearFrontend()
void InspectorProfilerAgent::restore()
{
- if (!m_state->getBoolean(ProfilerAgentState::profilerEnabled))
+ if (!m_state->booleanProperty(ProfilerAgentState::profilerEnabled, false))
return;
m_v8ProfilerAgent->restore();
ErrorString errorString;

Powered by Google App Engine
This is Rietveld 408576698