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

Side by Side Diff: Source/bindings/v8/ScriptController.cpp

Issue 212953003: TimelinePanel: provide scriptId in FunctionCall event. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2008, 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2008, 2009 Google Inc. All rights reserved.
3 * Copyright (C) 2009 Apple Inc. All rights reserved. 3 * Copyright (C) 2009 Apple Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 } 158 }
159 159
160 v8::Local<v8::Value> ScriptController::callFunction(ExecutionContext* context, v 8::Handle<v8::Function> function, v8::Handle<v8::Value> receiver, int argc, v8:: Handle<v8::Value> info[], v8::Isolate* isolate) 160 v8::Local<v8::Value> ScriptController::callFunction(ExecutionContext* context, v 8::Handle<v8::Function> function, v8::Handle<v8::Value> receiver, int argc, v8:: Handle<v8::Value> info[], v8::Isolate* isolate)
161 { 161 {
162 InspectorInstrumentationCookie cookie; 162 InspectorInstrumentationCookie cookie;
163 if (InspectorInstrumentation::timelineAgentEnabled(context)) { 163 if (InspectorInstrumentation::timelineAgentEnabled(context)) {
164 String resourceName; 164 String resourceName;
165 int lineNumber; 165 int lineNumber;
166 if (!resourceInfo(getBoundFunction(function), resourceName, lineNumber)) 166 if (!resourceInfo(getBoundFunction(function), resourceName, lineNumber))
167 return v8::Local<v8::Value>(); 167 return v8::Local<v8::Value>();
168 cookie = InspectorInstrumentation::willCallFunction(context, resourceNam e, lineNumber); 168 cookie = InspectorInstrumentation::willCallFunction(context, function->S criptId(), resourceName, lineNumber);
pfeldman 2014/03/26 16:28:58 Do we need the resourceName though?
169 } 169 }
170 170
171 v8::Local<v8::Value> result = V8ScriptRunner::callFunction(function, context , receiver, argc, info, isolate); 171 v8::Local<v8::Value> result = V8ScriptRunner::callFunction(function, context , receiver, argc, info, isolate);
172 172
173 InspectorInstrumentation::didCallFunction(cookie); 173 InspectorInstrumentation::didCallFunction(cookie);
174 return result; 174 return result;
175 } 175 }
176 176
177 v8::Local<v8::Value> ScriptController::executeScriptAndReturnValue(v8::Handle<v8 ::Context> context, const ScriptSourceCode& source, AccessControlStatus corsStat us) 177 v8::Local<v8::Value> ScriptController::executeScriptAndReturnValue(v8::Handle<v8 ::Context> context, const ScriptSourceCode& source, AccessControlStatus corsStat us)
178 { 178 {
(...skipping 460 matching lines...) Expand 10 before | Expand all | Expand 10 after
639 v8Results = evaluateHandleScope.Escape(resultArray); 639 v8Results = evaluateHandleScope.Escape(resultArray);
640 } 640 }
641 641
642 if (results && !v8Results.IsEmpty()) { 642 if (results && !v8Results.IsEmpty()) {
643 for (size_t i = 0; i < v8Results->Length(); ++i) 643 for (size_t i = 0; i < v8Results->Length(); ++i)
644 results->append(ScriptValue(v8Results->Get(i), m_isolate)); 644 results->append(ScriptValue(v8Results->Get(i), m_isolate));
645 } 645 }
646 } 646 }
647 647
648 } // namespace WebCore 648 } // namespace WebCore
OLDNEW
« no previous file with comments | « no previous file | Source/bindings/v8/V8WorkerGlobalScopeEventListener.cpp » ('j') | Source/devtools/front_end/TimelineUIUtils.js » ('J')

Powered by Google App Engine
This is Rietveld 408576698