| OLD | NEW |
| 1 {##############################################################################} | 1 {##############################################################################} |
| 2 {% macro attribute_getter(attribute, world_suffix) %} | 2 {% macro attribute_getter(attribute, world_suffix) %} |
| 3 {% filter conditional(attribute.conditional_string) %} | 3 {% filter conditional(attribute.conditional_string) %} |
| 4 static void {{attribute.name}}AttributeGetter{{world_suffix}}( | 4 static void {{attribute.name}}AttributeGetter{{world_suffix}}( |
| 5 {%- if attribute.is_expose_js_accessors %} | 5 {%- if attribute.is_expose_js_accessors %} |
| 6 const v8::FunctionCallbackInfo<v8::Value>& info | 6 const v8::FunctionCallbackInfo<v8::Value>& info |
| 7 {%- else %} | 7 {%- else %} |
| 8 const v8::PropertyCallbackInfo<v8::Value>& info | 8 const v8::PropertyCallbackInfo<v8::Value>& info |
| 9 {%- endif %}) | 9 {%- endif %}) |
| 10 { | 10 { |
| (...skipping 30 matching lines...) Expand all Loading... |
| 41 ASSERT(impl); | 41 ASSERT(impl); |
| 42 {% endif %} | 42 {% endif %} |
| 43 {% if interface_name == 'Window' and attribute.idl_type == 'EventHandler' %} | 43 {% if interface_name == 'Window' and attribute.idl_type == 'EventHandler' %} |
| 44 if (!impl->document()) | 44 if (!impl->document()) |
| 45 return; | 45 return; |
| 46 {% endif %} | 46 {% endif %} |
| 47 {# Local variables #} | 47 {# Local variables #} |
| 48 {% if attribute.is_call_with_execution_context %} | 48 {% if attribute.is_call_with_execution_context %} |
| 49 ExecutionContext* scriptContext = currentExecutionContext(info.GetIsolate())
; | 49 ExecutionContext* scriptContext = currentExecutionContext(info.GetIsolate())
; |
| 50 {% endif %} | 50 {% endif %} |
| 51 {% if attribute.is_call_with_new_script_state %} |
| 52 NewScriptState* state = NewScriptState::current(info.GetIsolate()); |
| 53 {% endif %} |
| 51 {% if attribute.is_check_security_for_node or | 54 {% if attribute.is_check_security_for_node or |
| 52 attribute.is_getter_raises_exception %} | 55 attribute.is_getter_raises_exception %} |
| 53 ExceptionState exceptionState(ExceptionState::GetterContext, "{{attribute.na
me}}", "{{interface_name}}", holder, info.GetIsolate()); | 56 ExceptionState exceptionState(ExceptionState::GetterContext, "{{attribute.na
me}}", "{{interface_name}}", holder, info.GetIsolate()); |
| 54 {% endif %} | 57 {% endif %} |
| 55 {% if attribute.is_nullable and not attribute.has_strict_type_checking %} | 58 {% if attribute.is_nullable and not attribute.has_strict_type_checking %} |
| 56 bool isNull = false; | 59 bool isNull = false; |
| 57 {% endif %} | 60 {% endif %} |
| 58 {# FIXME: consider always using a local variable for value #} | 61 {# FIXME: consider always using a local variable for value #} |
| 59 {% if attribute.cached_attribute_validation_method or | 62 {% if attribute.cached_attribute_validation_method or |
| 60 attribute.is_getter_raises_exception or | 63 attribute.is_getter_raises_exception or |
| (...skipping 256 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 317 {% endif %} | 320 {% endif %} |
| 318 {% if attribute.has_custom_setter %} | 321 {% if attribute.has_custom_setter %} |
| 319 {{v8_class}}::{{attribute.name}}AttributeSetterCustom(v8Value, info); | 322 {{v8_class}}::{{attribute.name}}AttributeSetterCustom(v8Value, info); |
| 320 {% else %} | 323 {% else %} |
| 321 {{cpp_class}}V8Internal::{{attribute.name}}AttributeSetter{{world_suffix}}(v
8Value, info); | 324 {{cpp_class}}V8Internal::{{attribute.name}}AttributeSetter{{world_suffix}}(v
8Value, info); |
| 322 {% endif %} | 325 {% endif %} |
| 323 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 326 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 324 } | 327 } |
| 325 {% endfilter %} | 328 {% endfilter %} |
| 326 {% endmacro %} | 329 {% endmacro %} |
| OLD | NEW |