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

Side by Side Diff: third_party/WebKit/Source/bindings/templates/attributes.cpp

Issue 1667653002: V8-binding: Use v8::Template::SetNativeDataProperty without setter for [Replaceable]. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Moved the [LenientThis] test to http/tests/. Created 4 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
OLDNEW
1 {% from 'utilities.cpp' import declare_enum_validation_variable, v8_value_to_loc al_cpp_value, check_origin_trial %} 1 {% from 'utilities.cpp' import declare_enum_validation_variable, v8_value_to_loc al_cpp_value, check_origin_trial %}
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 441 matching lines...) Expand 10 before | Expand all | Expand 10 after
452 452
453 453
454 {##############################################################################} 454 {##############################################################################}
455 {% macro attribute_configuration(attribute) %} 455 {% macro attribute_configuration(attribute) %}
456 {% from 'utilities.cpp' import property_location %} 456 {% from 'utilities.cpp' import property_location %}
457 {% if attribute.constructor_type %} 457 {% if attribute.constructor_type %}
458 {% set getter_callback = 458 {% set getter_callback =
459 '%sV8Internal::%sConstructorGetterCallback' % (cpp_class_or_partial, attr ibute.name) 459 '%sV8Internal::%sConstructorGetterCallback' % (cpp_class_or_partial, attr ibute.name)
460 if attribute.needs_constructor_getter_callback else 460 if attribute.needs_constructor_getter_callback else
461 'v8ConstructorAttributeGetter' %} 461 'v8ConstructorAttributeGetter' %}
462 {% set setter_callback = 462 {% set setter_callback = '0' %}
463 '%sV8Internal::%sAttributeSetterCallback' % (cpp_class_or_partial, attrib ute.name)
464 if attribute.needs_constructor_setter_callback else
465 '%sV8Internal::%sConstructorAttributeSetterCallback' % (cpp_class_or_part ial, cpp_class) %}
466 {% else %}{# regular attributes #} 463 {% else %}{# regular attributes #}
467 {% set getter_callback = '%sV8Internal::%sAttributeGetterCallback' % 464 {% set getter_callback = '%sV8Internal::%sAttributeGetterCallback' %
468 (cpp_class_or_partial, attribute.name) %} 465 (cpp_class_or_partial, attribute.name) %}
469 {% set setter_callback = '%sV8Internal::%sAttributeSetterCallback' % 466 {% set setter_callback = '%sV8Internal::%sAttributeSetterCallback' %
470 (cpp_class_or_partial, attribute.name) 467 (cpp_class_or_partial, attribute.name)
471 if attribute.has_setter else '0' %} 468 if attribute.has_setter else '0' %}
472 {% endif %} 469 {% endif %}
473 {% set getter_callback_for_main_world = 470 {% set getter_callback_for_main_world =
474 '%sForMainWorld' % getter_callback 471 '%sForMainWorld' % getter_callback
475 if attribute.is_per_world_bindings else '0' %} 472 if attribute.is_per_world_bindings else '0' %}
(...skipping 26 matching lines...) Expand all
502 setter_callback_for_main_world, 499 setter_callback_for_main_world,
503 wrapper_type_info, 500 wrapper_type_info,
504 access_control, 501 access_control,
505 property_attribute, 502 property_attribute,
506 only_exposed_to_private_script, 503 only_exposed_to_private_script,
507 property_location(attribute), 504 property_location(attribute),
508 holder_check, 505 holder_check,
509 ] %} 506 ] %}
510 {{'{'}}{{attribute_configuration_list | join(', ')}}{{'}'}} 507 {{'{'}}{{attribute_configuration_list | join(', ')}}{{'}'}}
511 {%- endmacro %} 508 {%- endmacro %}
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698