OLD | NEW |
---|---|
1 {% from 'utilities.cpp' import declare_enum_validation_variable, v8_value_to_loc al_cpp_value %} | 1 {% from 'utilities.cpp' import declare_enum_validation_variable, v8_value_to_loc al_cpp_value %} |
2 | 2 |
3 {##############################################################################} | 3 {##############################################################################} |
4 {% macro attribute_getter(attribute, world_suffix) %} | 4 {% macro attribute_getter(attribute, world_suffix) %} |
5 static void {{attribute.name}}AttributeGetter{{world_suffix}}( | 5 static void {{attribute.name}}AttributeGetter{{world_suffix}}( |
6 {%- if attribute.is_data_type_property %} | 6 {%- if attribute.is_data_type_property %} |
7 const v8::PropertyCallbackInfo<v8::Value>& info | 7 const v8::PropertyCallbackInfo<v8::Value>& info |
8 {%- else %} | 8 {%- else %} |
9 const v8::FunctionCallbackInfo<v8::Value>& info | 9 const v8::FunctionCallbackInfo<v8::Value>& info |
10 {%- endif %}) | 10 {%- endif %}) |
(...skipping 481 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
492 ' | '.join(attribute.access_control_list) %} | 492 ' | '.join(attribute.access_control_list) %} |
493 {% else %} | 493 {% else %} |
494 {% set access_control = 'v8::DEFAULT' %} | 494 {% set access_control = 'v8::DEFAULT' %} |
495 {% endif %} | 495 {% endif %} |
496 {% set property_attribute = 'static_cast<v8::PropertyAttribute>(%s)' % | 496 {% set property_attribute = 'static_cast<v8::PropertyAttribute>(%s)' % |
497 ' | '.join(attribute.property_attributes) %} | 497 ' | '.join(attribute.property_attributes) %} |
498 {% set only_exposed_to_private_script = | 498 {% set only_exposed_to_private_script = |
499 'V8DOMConfiguration::OnlyExposedToPrivateScript' | 499 'V8DOMConfiguration::OnlyExposedToPrivateScript' |
500 if attribute.only_exposed_to_private_script else | 500 if attribute.only_exposed_to_private_script else |
501 'V8DOMConfiguration::ExposedToAllScripts' %} | 501 'V8DOMConfiguration::ExposedToAllScripts' %} |
502 {% set surrogate_name = | |
503 '"%s"' % attribute.surrogate_name | |
504 if attribute.is_store_in_field else | |
505 '0' %} | |
jochen (gone - plz use gerrit)
2016/09/15 08:20:51
nullptr?
Alfonso
2016/09/16 14:21:48
All the others callbacks seems to be using '0', I'
| |
502 {% set holder_check = 'V8DOMConfiguration::DoNotCheckHolder' | 506 {% set holder_check = 'V8DOMConfiguration::DoNotCheckHolder' |
503 if attribute.is_lenient_this else 'V8DOMConfiguration::CheckHolder' %} | 507 if attribute.is_lenient_this else 'V8DOMConfiguration::CheckHolder' %} |
504 {% set attribute_configuration_list = [ | 508 {% set attribute_configuration_list = [ |
505 '"%s"' % attribute.name, | 509 '"%s"' % attribute.name, |
506 getter_callback, | 510 getter_callback, |
507 setter_callback, | 511 setter_callback, |
508 getter_callback_for_main_world, | 512 getter_callback_for_main_world, |
509 setter_callback_for_main_world, | 513 setter_callback_for_main_world, |
510 getter_builder_callback, | 514 getter_builder_callback, |
515 surrogate_name, | |
511 wrapper_type_info, | 516 wrapper_type_info, |
512 access_control, | 517 access_control, |
513 property_attribute, | 518 property_attribute, |
514 only_exposed_to_private_script, | 519 only_exposed_to_private_script, |
515 property_location(attribute), | 520 property_location(attribute), |
516 holder_check, | 521 holder_check, |
517 ] %} | 522 ] %} |
518 {{'{'}}{{attribute_configuration_list | join(', ')}}{{'}'}} | 523 {{'{'}}{{attribute_configuration_list | join(', ')}}{{'}'}} |
519 {%- endmacro %} | 524 {%- endmacro %} |
OLD | NEW |