Chromium Code Reviews| Index: Source/bindings/templates/methods.cpp |
| diff --git a/Source/bindings/templates/methods.cpp b/Source/bindings/templates/methods.cpp |
| index cddc95d21289ca3839308948ca040e90ac5892c5..a1eca4c4bdf2ecd09e53d0f017b0f84875e1e1da 100644 |
| --- a/Source/bindings/templates/methods.cpp |
| +++ b/Source/bindings/templates/methods.cpp |
| @@ -68,10 +68,17 @@ static void {{method.name}}Method(const v8::FunctionCallbackInfo<v8::Value>& inf |
| {##############################################################################} |
| -{% macro method_callback(method) %} |
| +{% macro method_callback(method, world_suffix) %} |
| static void {{method.name}}MethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| { |
| TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| + {% if world_suffix in method.activity_logging_world_list %} |
| + V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->GetCurrentContext()); |
| + if (contextData && contextData->activityLogger()) { |
| + Vector<v8::Handle<v8::Value> > loggerArgs = toVectorOfArguments(info); |
|
haraken
2013/11/05 06:27:37
Shall we use toNativeArguments(info, 0), and then
Nils Barth (inactive)
2013/11/05 06:40:57
Sounds good; will do in a followup!
|
| + contextData->activityLogger()->log("{{interface_name}}.{{method.name}}", info.Length(), loggerArgs.data(), "Method"); |
| + } |
| + {% endif %} |
| {{cpp_class_name}}V8Internal::{{method.name}}Method(info); |
| TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); |
| } |