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

Unified Diff: third_party/WebKit/Source/core/inspector/InspectorHeapProfilerAgent.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/InspectorHeapProfilerAgent.cpp
diff --git a/third_party/WebKit/Source/core/inspector/InspectorHeapProfilerAgent.cpp b/third_party/WebKit/Source/core/inspector/InspectorHeapProfilerAgent.cpp
index 1fe4c09225c3bcf16576dae33d89b4917c53413a..90d4547e25b64d021630787bc340cfc56eef6233 100644
--- a/third_party/WebKit/Source/core/inspector/InspectorHeapProfilerAgent.cpp
+++ b/third_party/WebKit/Source/core/inspector/InspectorHeapProfilerAgent.cpp
@@ -35,7 +35,6 @@
#include "core/frame/LocalDOMWindow.h"
#include "core/inspector/InjectedScript.h"
#include "core/inspector/InjectedScriptHost.h"
-#include "core/inspector/InspectorState.h"
#include "core/inspector/RemoteObjectId.h"
#include "platform/Timer.h"
#include "wtf/CurrentTime.h"
@@ -203,10 +202,10 @@ InspectorHeapProfilerAgent::~InspectorHeapProfilerAgent()
void InspectorHeapProfilerAgent::restore()
{
- if (m_state->getBoolean(HeapProfilerAgentState::heapProfilerEnabled))
+ if (m_state->booleanProperty(HeapProfilerAgentState::heapProfilerEnabled, false))
frontend()->resetProfiles();
- if (m_state->getBoolean(HeapProfilerAgentState::heapObjectsTrackingEnabled))
- startTrackingHeapObjectsInternal(m_state->getBoolean(HeapProfilerAgentState::allocationTrackingEnabled));
+ if (m_state->booleanProperty(HeapProfilerAgentState::heapObjectsTrackingEnabled, false))
+ startTrackingHeapObjectsInternal(m_state->booleanProperty(HeapProfilerAgentState::allocationTrackingEnabled, false));
}
void InspectorHeapProfilerAgent::collectGarbage(ErrorString*)

Powered by Google App Engine
This is Rietveld 408576698