| OLD | NEW |
| 1 {% extends 'interface_base.cpp.tmpl' %} | 1 {% extends 'interface_base.cpp.tmpl' %} |
| 2 | 2 |
| 3 {##############################################################################} | 3 {##############################################################################} |
| 4 {% block indexed_property_getter %} | 4 {% block indexed_property_getter %} |
| 5 {% if indexed_property_getter and not indexed_property_getter.is_custom %} | 5 {% if indexed_property_getter and not indexed_property_getter.is_custom %} |
| 6 {% set getter = indexed_property_getter %} | 6 {% set getter = indexed_property_getter %} |
| 7 static void indexedPropertyGetter(uint32_t index, const v8::PropertyCallbackInfo
<v8::Value>& info) { | 7 static void indexedPropertyGetter(uint32_t index, const v8::PropertyCallbackInfo
<v8::Value>& info) { |
| 8 {% if getter.is_raises_exception %} | 8 {% if getter.is_raises_exception %} |
| 9 ExceptionState exceptionState(info.GetIsolate(), ExceptionState::IndexedGetter
Context, "{{interface_name}}"); | 9 ExceptionState exceptionState(info.GetIsolate(), ExceptionState::IndexedGetter
Context, "{{interface_name}}"); |
| 10 {% endif %} | 10 {% endif %} |
| (...skipping 836 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 847 return value->Is{{interface_name}}() ? toImpl(v8::Local<v8::Object>::Cast(valu
e)) : nullptr; | 847 return value->Is{{interface_name}}() ? toImpl(v8::Local<v8::Object>::Cast(valu
e)) : nullptr; |
| 848 {% else %} | 848 {% else %} |
| 849 return hasInstance(value, isolate) ? toImpl(v8::Local<v8::Object>::Cast(value)
) : nullptr; | 849 return hasInstance(value, isolate) ? toImpl(v8::Local<v8::Object>::Cast(value)
) : nullptr; |
| 850 {% endif %} | 850 {% endif %} |
| 851 } | 851 } |
| 852 | 852 |
| 853 {% endblock %} | 853 {% endblock %} |
| 854 | 854 |
| 855 | 855 |
| 856 {##############################################################################} | 856 {##############################################################################} |
| 857 {% block native_value_traits %} |
| 858 {{cpp_class}}* NativeValueTraits<{{cpp_class}}>::nativeValue(v8::Isolate* isolat
e, v8::Local<v8::Value> value, ExceptionState& exceptionState) { |
| 859 return {{v8_class}}::toImplWithTypeCheck(isolate, value); |
| 860 } |
| 861 |
| 862 {% endblock %} |
| 863 |
| 864 |
| 865 {##############################################################################} |
| 857 {% block partial_interface %} | 866 {% block partial_interface %} |
| 858 {% if has_partial_interface %} | 867 {% if has_partial_interface %} |
| 859 {% if needs_runtime_enabled_installer %} | 868 {% if needs_runtime_enabled_installer %} |
| 860 InstallRuntimeEnabledFunction {{v8_class}}::install{{v8_class}}RuntimeEnabledFun
ction = | 869 InstallRuntimeEnabledFunction {{v8_class}}::install{{v8_class}}RuntimeEnabledFun
ction = |
| 861 &{{v8_class}}::installRuntimeEnabledFeatures; | 870 &{{v8_class}}::installRuntimeEnabledFeatures; |
| 862 {% endif %} | 871 {% endif %} |
| 863 | 872 |
| 864 InstallTemplateFunction {{v8_class}}::install{{v8_class}}TemplateFunction = | 873 InstallTemplateFunction {{v8_class}}::install{{v8_class}}TemplateFunction = |
| 865 &{{v8_class}}::install{{v8_class}}Template; | 874 &{{v8_class}}::install{{v8_class}}Template; |
| 866 | 875 |
| (...skipping 17 matching lines...) Expand all Loading... |
| 884 } | 893 } |
| 885 | 894 |
| 886 {% for method in methods if method.overloads and method.overloads.has_partial_ov
erloads %} | 895 {% for method in methods if method.overloads and method.overloads.has_partial_ov
erloads %} |
| 887 void {{v8_class}}::register{{method.name | blink_capitalize}}MethodForPartialInt
erface(void (*method)(const v8::FunctionCallbackInfo<v8::Value>&)) { | 896 void {{v8_class}}::register{{method.name | blink_capitalize}}MethodForPartialInt
erface(void (*method)(const v8::FunctionCallbackInfo<v8::Value>&)) { |
| 888 {{cpp_class}}V8Internal::{{method.name}}MethodForPartialInterface = method; | 897 {{cpp_class}}V8Internal::{{method.name}}MethodForPartialInterface = method; |
| 889 } | 898 } |
| 890 | 899 |
| 891 {% endfor %} | 900 {% endfor %} |
| 892 {% endif %} | 901 {% endif %} |
| 893 {% endblock %} | 902 {% endblock %} |
| OLD | NEW |