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

Side by Side Diff: third_party/WebKit/Source/platform/v8_inspector/V8DebuggerImpl.cpp

Issue 1859293002: [DevTools] Move Console to v8_inspector (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebased Created 4 years, 8 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2010-2011 Google Inc. All rights reserved. 2 * Copyright (c) 2010-2011 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 813 matching lines...) Expand 10 before | Expand all | Expand 10 after
824 if (!m_contexts.contains(contextGroupId)) 824 if (!m_contexts.contains(contextGroupId))
825 return nullptr; 825 return nullptr;
826 return m_contexts.get(contextGroupId); 826 return m_contexts.get(contextGroupId);
827 } 827 }
828 828
829 V8InspectorSessionImpl* V8DebuggerImpl::sessionForContextGroup(int contextGroupI d) 829 V8InspectorSessionImpl* V8DebuggerImpl::sessionForContextGroup(int contextGroupI d)
830 { 830 {
831 return contextGroupId ? m_sessions.get(contextGroupId) : nullptr; 831 return contextGroupId ? m_sessions.get(contextGroupId) : nullptr;
832 } 832 }
833 833
834 v8::MaybeLocal<v8::FunctionTemplate> V8DebuggerImpl::functionTemplate(const Stri ng16& name)
835 {
836 if (!m_templates.contains(name))
837 return v8::MaybeLocal<v8::FunctionTemplate>();
838 return m_templates.get(name)->Get(m_isolate);
839 }
840
841 void V8DebuggerImpl::setFunctionTemplate(const String16& name, v8::Local<v8::Fun ctionTemplate> functionTemplate)
842 {
843 OwnPtr<v8::Global<v8::FunctionTemplate>> global = adoptPtr(new v8::Global<v8 ::FunctionTemplate>(m_isolate, functionTemplate));
844 m_templates.set(name, global.release());
845 }
846
834 } // namespace blink 847 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698