| OLD | NEW |
| 1 {% extends 'interface_base.cpp' %} | 1 {% extends 'interface_base.cpp' %} |
| 2 | 2 |
| 3 | 3 |
| 4 {##############################################################################} | 4 {##############################################################################} |
| 5 {% block indexed_property_getter %} | 5 {% block indexed_property_getter %} |
| 6 {% if indexed_property_getter and not indexed_property_getter.is_custom %} | 6 {% if indexed_property_getter and not indexed_property_getter.is_custom %} |
| 7 {% set getter = indexed_property_getter %} | 7 {% set getter = indexed_property_getter %} |
| 8 static void indexedPropertyGetter(uint32_t index, const v8::PropertyCallbackInfo
<v8::Value>& info) | 8 static void indexedPropertyGetter(uint32_t index, const v8::PropertyCallbackInfo
<v8::Value>& info) |
| 9 { | 9 { |
| 10 {{cpp_class}}* impl = {{v8_class}}::toImpl(info.Holder()); | 10 {{cpp_class}}* impl = {{v8_class}}::toImpl(info.Holder()); |
| (...skipping 572 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 583 {% endblock %} | 583 {% endblock %} |
| 584 | 584 |
| 585 | 585 |
| 586 {##############################################################################} | 586 {##############################################################################} |
| 587 {% block constructor_callback %} | 587 {% block constructor_callback %} |
| 588 {% if constructors or has_custom_constructor or has_event_constructor %} | 588 {% if constructors or has_custom_constructor or has_event_constructor %} |
| 589 void {{v8_class}}::constructorCallback(const v8::FunctionCallbackInfo<v8::Value>
& info) | 589 void {{v8_class}}::constructorCallback(const v8::FunctionCallbackInfo<v8::Value>
& info) |
| 590 { | 590 { |
| 591 TRACE_EVENT_SCOPED_SAMPLING_STATE("blink", "DOMConstructor"); | 591 TRACE_EVENT_SCOPED_SAMPLING_STATE("blink", "DOMConstructor"); |
| 592 {% if measure_as %} | 592 {% if measure_as %} |
| 593 UseCounter::countIfNotPrivateScript(info.GetIsolate(), callingExecutionConte
xt(info.GetIsolate()), UseCounter::{{measure_as('Constructor')}}); | 593 UseCounter::countIfNotPrivateScript(info.GetIsolate(), currentExecutionConte
xt(info.GetIsolate()), UseCounter::{{measure_as('Constructor')}}); |
| 594 {% endif %} | 594 {% endif %} |
| 595 if (!info.IsConstructCall()) { | 595 if (!info.IsConstructCall()) { |
| 596 V8ThrowException::throwTypeError(info.GetIsolate(), ExceptionMessages::c
onstructorNotCallableAsFunction("{{interface_name}}")); | 596 V8ThrowException::throwTypeError(info.GetIsolate(), ExceptionMessages::c
onstructorNotCallableAsFunction("{{interface_name}}")); |
| 597 return; | 597 return; |
| 598 } | 598 } |
| 599 | 599 |
| 600 if (ConstructorMode::current(info.GetIsolate()) == ConstructorMode::WrapExis
tingObject) { | 600 if (ConstructorMode::current(info.GetIsolate()) == ConstructorMode::WrapExis
tingObject) { |
| 601 v8SetReturnValue(info, info.Holder()); | 601 v8SetReturnValue(info, info.Holder()); |
| 602 return; | 602 return; |
| 603 } | 603 } |
| (...skipping 375 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 979 | 979 |
| 980 {% for method in methods if method.overloads and method.overloads.has_partial_ov
erloads %} | 980 {% for method in methods if method.overloads and method.overloads.has_partial_ov
erloads %} |
| 981 void {{v8_class}}::register{{method.name | blink_capitalize}}MethodForPartialInt
erface(void (*method)(const v8::FunctionCallbackInfo<v8::Value>&)) | 981 void {{v8_class}}::register{{method.name | blink_capitalize}}MethodForPartialInt
erface(void (*method)(const v8::FunctionCallbackInfo<v8::Value>&)) |
| 982 { | 982 { |
| 983 {{cpp_class}}V8Internal::{{method.name}}MethodForPartialInterface = method; | 983 {{cpp_class}}V8Internal::{{method.name}}MethodForPartialInterface = method; |
| 984 } | 984 } |
| 985 | 985 |
| 986 {% endfor %} | 986 {% endfor %} |
| 987 {% endif %} | 987 {% endif %} |
| 988 {% endblock %} | 988 {% endblock %} |
| OLD | NEW |