Chromium Code Reviews| Index: third_party/WebKit/Source/platform/v8_inspector/V8DebuggerImpl.cpp |
| diff --git a/third_party/WebKit/Source/platform/v8_inspector/V8DebuggerImpl.cpp b/third_party/WebKit/Source/platform/v8_inspector/V8DebuggerImpl.cpp |
| index 19255d87f048abb839d7996486e5296d7f828553..14a198781e11066b65c3b3681fb688c3e503f3d8 100644 |
| --- a/third_party/WebKit/Source/platform/v8_inspector/V8DebuggerImpl.cpp |
| +++ b/third_party/WebKit/Source/platform/v8_inspector/V8DebuggerImpl.cpp |
| @@ -37,6 +37,7 @@ |
| #include "platform/v8_inspector/ScriptBreakpoint.h" |
| #include "platform/v8_inspector/V8DebuggerAgentImpl.h" |
| #include "platform/v8_inspector/V8InspectorSessionImpl.h" |
| +#include "platform/v8_inspector/V8ProfilerAgentImpl.h" |
|
dgozman
2016/04/12 23:21:58
unused?
kozy
2016/04/12 23:34:26
Done.
|
| #include "platform/v8_inspector/V8RuntimeAgentImpl.h" |
| #include "platform/v8_inspector/V8StackTraceImpl.h" |
| #include "platform/v8_inspector/V8StringUtil.h" |
| @@ -770,7 +771,7 @@ void V8DebuggerImpl::contextCreated(const V8ContextInfo& info) |
| m_contexts.set(info.contextGroupId, adoptPtr(new ContextByIdMap())); |
| ASSERT(!m_contexts.get(info.contextGroupId)->contains(contextId)); |
| - OwnPtr<InspectedContext> contextOwner = adoptPtr(new InspectedContext(this, info, contextId)); |
| + OwnPtr<InspectedContext> contextOwner = adoptPtr(new InspectedContext(this, info, contextId, info.hasMemoryOnConsole)); |
| InspectedContext* inspectedContext = contextOwner.get(); |
| m_contexts.get(info.contextGroupId)->set(contextId, contextOwner.release()); |
| @@ -835,4 +836,17 @@ V8InspectorSessionImpl* V8DebuggerImpl::sessionForContextGroup(int contextGroupI |
| return contextGroupId ? m_sessions.get(contextGroupId) : nullptr; |
| } |
| +v8::MaybeLocal<v8::FunctionTemplate> V8DebuggerImpl::functionTemplate(const String16& name) |
| +{ |
| + if (!m_templates.contains(name)) |
| + return v8::MaybeLocal<v8::FunctionTemplate>(); |
| + return v8::Local<v8::FunctionTemplate>::New(m_isolate, *m_templates.get(name)); |
|
dgozman
2016/04/12 23:21:58
global has .Get(isolate)
kozy
2016/04/12 23:34:26
Done.
|
| +} |
| + |
| +void V8DebuggerImpl::setFunctionTemplate(const String16& name, v8::Local<v8::FunctionTemplate> functionTemplate) |
| +{ |
| + OwnPtr<v8::Global<v8::FunctionTemplate>> global = adoptPtr(new v8::Global<v8::FunctionTemplate>(m_isolate, functionTemplate)); |
| + m_templates.set(name, global.release()); |
| +} |
| + |
| } // namespace blink |