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

Unified Diff: third_party/WebKit/Source/platform/v8_inspector/V8Console.cpp

Issue 2199943004: [DevTools] Rename V8Debugger to V8Inspector. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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/platform/v8_inspector/V8Console.cpp
diff --git a/third_party/WebKit/Source/platform/v8_inspector/V8Console.cpp b/third_party/WebKit/Source/platform/v8_inspector/V8Console.cpp
index 24407485ab587dd9a1cedf9c25c471e1ced9514b..4556d45dcf2f6b4114ceb2b5a4accd626d10c5ff 100644
--- a/third_party/WebKit/Source/platform/v8_inspector/V8Console.cpp
+++ b/third_party/WebKit/Source/platform/v8_inspector/V8Console.cpp
@@ -11,13 +11,13 @@
#include "platform/v8_inspector/V8Compat.h"
#include "platform/v8_inspector/V8ConsoleMessage.h"
#include "platform/v8_inspector/V8DebuggerAgentImpl.h"
-#include "platform/v8_inspector/V8DebuggerImpl.h"
+#include "platform/v8_inspector/V8InspectorImpl.h"
#include "platform/v8_inspector/V8InspectorSessionImpl.h"
#include "platform/v8_inspector/V8ProfilerAgentImpl.h"
#include "platform/v8_inspector/V8RuntimeAgentImpl.h"
#include "platform/v8_inspector/V8StackTraceImpl.h"
#include "platform/v8_inspector/V8StringUtil.h"
-#include "platform/v8_inspector/public/V8DebuggerClient.h"
+#include "platform/v8_inspector/public/V8InspectorClient.h"
namespace blink {
@@ -36,7 +36,7 @@ public:
, m_isolate(info.GetIsolate())
, m_context(info.GetIsolate()->GetCurrentContext())
, m_inspectedContext(nullptr)
- , m_debuggerClient(nullptr)
+ , m_inspectorClient(nullptr)
{
}
@@ -65,15 +65,15 @@ public:
return m_inspectedContext;
}
- V8DebuggerClient* ensureDebuggerClient()
+ V8InspectorClient* ensureDebuggerClient()
{
- if (m_debuggerClient)
- return m_debuggerClient;
+ if (m_inspectorClient)
+ return m_inspectorClient;
InspectedContext* inspectedContext = ensureInspectedContext();
if (!inspectedContext)
return nullptr;
- m_debuggerClient = inspectedContext->debugger()->client();
- return m_debuggerClient;
+ m_inspectorClient = inspectedContext->inspector()->client();
+ return m_inspectorClient;
}
void reportCall(ConsoleAPIType type)
@@ -107,9 +107,9 @@ public:
InspectedContext* inspectedContext = ensureInspectedContext();
if (!inspectedContext)
return;
- V8DebuggerImpl* debugger = inspectedContext->debugger();
- std::unique_ptr<V8ConsoleMessage> message = V8ConsoleMessage::createForConsoleAPI(debugger->client()->currentTimeMS(), type, arguments, debugger->captureStackTraceImpl(false), inspectedContext);
- debugger->ensureConsoleMessageStorage(inspectedContext->contextGroupId())->addMessage(std::move(message));
+ V8InspectorImpl* inspector = inspectedContext->inspector();
+ std::unique_ptr<V8ConsoleMessage> message = V8ConsoleMessage::createForConsoleAPI(inspector->client()->currentTimeMS(), type, arguments, inspector->captureStackTraceImpl(false), inspectedContext);
+ inspector->ensureConsoleMessageStorage(inspectedContext->contextGroupId())->addMessage(std::move(message));
}
void reportDeprecatedCall(const char* id, const String16& message)
@@ -233,7 +233,7 @@ public:
InspectedContext* inspectedContext = ensureInspectedContext();
if (!inspectedContext)
return nullptr;
- return inspectedContext->debugger()->sessionForContextGroup(inspectedContext->contextGroupId());
+ return inspectedContext->inspector()->sessionForContextGroup(inspectedContext->contextGroupId());
}
private:
@@ -242,7 +242,7 @@ private:
v8::Local<v8::Context> m_context;
v8::Local<v8::Object> m_console;
InspectedContext* m_inspectedContext;
- V8DebuggerClient* m_debuggerClient;
+ V8InspectorClient* m_inspectorClient;
bool checkAndSetPrivateFlagOnConsole(const char* name, bool defaultValue)
{
@@ -413,7 +413,7 @@ void V8Console::profileEndCallback(const v8::FunctionCallbackInfo<v8::Value>& in
static void timeFunction(const v8::FunctionCallbackInfo<v8::Value>& info, bool timelinePrefix)
{
ConsoleHelper helper(info);
- if (V8DebuggerClient* client = helper.ensureDebuggerClient()) {
+ if (V8InspectorClient* client = helper.ensureDebuggerClient()) {
String16 protocolTitle = helper.firstArgToString("default");
if (timelinePrefix)
protocolTitle = "Timeline '" + protocolTitle + "'";
@@ -429,7 +429,7 @@ static void timeFunction(const v8::FunctionCallbackInfo<v8::Value>& info, bool t
static void timeEndFunction(const v8::FunctionCallbackInfo<v8::Value>& info, bool timelinePrefix)
{
ConsoleHelper helper(info);
- if (V8DebuggerClient* client = helper.ensureDebuggerClient()) {
+ if (V8InspectorClient* client = helper.ensureDebuggerClient()) {
String16 protocolTitle = helper.firstArgToString("default");
if (timelinePrefix)
protocolTitle = "Timeline '" + protocolTitle + "'";
@@ -469,13 +469,13 @@ void V8Console::timeEndCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
void V8Console::timeStampCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
{
ConsoleHelper helper(info);
- if (V8DebuggerClient* client = helper.ensureDebuggerClient())
+ if (V8InspectorClient* client = helper.ensureDebuggerClient())
client->consoleTimeStamp(helper.firstArgToString(String16()));
}
void V8Console::memoryGetterCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
{
- if (V8DebuggerClient* client = ConsoleHelper(info).ensureDebuggerClient()) {
+ if (V8InspectorClient* client = ConsoleHelper(info).ensureDebuggerClient()) {
v8::Local<v8::Value> memoryValue;
if (!client->memoryInfo(info.GetIsolate(), info.GetIsolate()->GetCurrentContext()).ToLocal(&memoryValue))
return;
@@ -731,7 +731,7 @@ v8::Local<v8::Object> V8Console::createCommandLineAPI(InspectedContext* inspecte
createBoundFunctionProperty(context, commandLineAPI, "$3", V8Console::inspectedObject3);
createBoundFunctionProperty(context, commandLineAPI, "$4", V8Console::inspectedObject4);
- inspectedContext->debugger()->client()->installAdditionalCommandLineAPI(context, commandLineAPI);
+ inspectedContext->inspector()->client()->installAdditionalCommandLineAPI(context, commandLineAPI);
commandLineAPI->SetPrivate(context, inspectedContextPrivateKey(isolate), v8::External::New(isolate, inspectedContext));
return commandLineAPI;

Powered by Google App Engine
This is Rietveld 408576698