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

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

Issue 2139543002: [DevTools] Report console API calls through Runtime. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebased 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/V8RuntimeAgentImpl.cpp
diff --git a/third_party/WebKit/Source/platform/v8_inspector/V8RuntimeAgentImpl.cpp b/third_party/WebKit/Source/platform/v8_inspector/V8RuntimeAgentImpl.cpp
index 61b783739eebd4409d5c69bc9a40a9676ea8bc08..a30ac2a04fe99854df9bdff098c2398bdf7cd665 100644
--- a/third_party/WebKit/Source/platform/v8_inspector/V8RuntimeAgentImpl.cpp
+++ b/third_party/WebKit/Source/platform/v8_inspector/V8RuntimeAgentImpl.cpp
@@ -370,7 +370,7 @@ void V8RuntimeAgentImpl::enable(ErrorString* errorString)
m_session->reportAllContexts(this);
V8ConsoleMessageStorage* storage = m_session->debugger()->ensureConsoleMessageStorage(m_session->contextGroupId());
for (const auto& message : storage->messages()) {
- if (message->origin() == V8MessageOrigin::kException || message->origin() == V8MessageOrigin::kRevokedException)
+ if (message->origin() != V8MessageOrigin::kExternalConsole)
reportMessage(message.get(), false);
}
}
@@ -427,7 +427,7 @@ void V8RuntimeAgentImpl::inspect(std::unique_ptr<protocol::Runtime::RemoteObject
m_frontend.inspectRequested(std::move(objectToInspect), std::move(hints));
}
-void V8RuntimeAgentImpl::exceptionMessageAdded(V8ConsoleMessage* message)
+void V8RuntimeAgentImpl::messageAdded(V8ConsoleMessage* message)
{
if (m_enabled)
reportMessage(message, true);
@@ -435,7 +435,7 @@ void V8RuntimeAgentImpl::exceptionMessageAdded(V8ConsoleMessage* message)
void V8RuntimeAgentImpl::reportMessage(V8ConsoleMessage* message, bool generatePreview)
{
- DCHECK(message->origin() == V8MessageOrigin::kException || message->origin() == V8MessageOrigin::kRevokedException);
+ DCHECK(message->origin() != V8MessageOrigin::kExternalConsole);
message->reportToFrontend(&m_frontend, m_session, generatePreview);
m_frontend.flush();
}

Powered by Google App Engine
This is Rietveld 408576698