| 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 295 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 306 UseCounter::count(callingExecutionContext(info.GetIsolate()), UseCounter::{{
attribute.measure_as}}); | 306 UseCounter::count(callingExecutionContext(info.GetIsolate()), UseCounter::{{
attribute.measure_as}}); |
| 307 {% endif %} | 307 {% endif %} |
| 308 {% if world_suffix in attribute.activity_logging_world_list_for_setter %} | 308 {% if world_suffix in attribute.activity_logging_world_list_for_setter %} |
| 309 ScriptState* scriptState = ScriptState::from(info.GetIsolate()->GetCurrentCo
ntext()); | 309 ScriptState* scriptState = ScriptState::from(info.GetIsolate()->GetCurrentCo
ntext()); |
| 310 V8PerContextData* contextData = scriptState->perContextData(); | 310 V8PerContextData* contextData = scriptState->perContextData(); |
| 311 {% if attribute.activity_logging_world_check %} | 311 {% if attribute.activity_logging_world_check %} |
| 312 if (scriptState->world().isIsolatedWorld() && contextData && contextData->ac
tivityLogger()) { | 312 if (scriptState->world().isIsolatedWorld() && contextData && contextData->ac
tivityLogger()) { |
| 313 {% else %} | 313 {% else %} |
| 314 if (contextData && contextData->activityLogger()) { | 314 if (contextData && contextData->activityLogger()) { |
| 315 {% endif %} | 315 {% endif %} |
| 316 {% if attribute.activity_logging_include_old_value_for_setter %} | |
| 317 {{cpp_class}}* impl = {{v8_class}}::toNative(info.Holder()); | |
| 318 {% if attribute.cpp_value_original %} | |
| 319 {{attribute.cpp_type}} {{attribute.cpp_value}}({{attribute.cpp_value_ori
ginal}}); | |
| 320 {% endif %} | |
| 321 v8::Handle<v8::Value> originalValue = {{attribute.cpp_value_to_v8_value}
}; | |
| 322 contextData->activityLogger()->logSetter("{{interface_name}}.{{attribute
.name}}", v8Value, originalValue); | |
| 323 {% else %} | |
| 324 contextData->activityLogger()->logSetter("{{interface_name}}.{{attribute
.name}}", v8Value); | 316 contextData->activityLogger()->logSetter("{{interface_name}}.{{attribute
.name}}", v8Value); |
| 325 {% endif %} | |
| 326 } | 317 } |
| 327 {% endif %} | 318 {% endif %} |
| 328 {% if attribute.is_custom_element_callbacks or attribute.is_reflect %} | 319 {% if attribute.is_custom_element_callbacks or attribute.is_reflect %} |
| 329 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 320 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 330 {% endif %} | 321 {% endif %} |
| 331 {% if attribute.has_custom_setter %} | 322 {% if attribute.has_custom_setter %} |
| 332 {{v8_class}}::{{attribute.name}}AttributeSetterCustom(v8Value, info); | 323 {{v8_class}}::{{attribute.name}}AttributeSetterCustom(v8Value, info); |
| 333 {% else %} | 324 {% else %} |
| 334 {{cpp_class}}V8Internal::{{attribute.name}}AttributeSetter{{world_suffix}}(v
8Value, info); | 325 {{cpp_class}}V8Internal::{{attribute.name}}AttributeSetter{{world_suffix}}(v
8Value, info); |
| 335 {% endif %} | 326 {% endif %} |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 400 if (!PrivateScriptRunner::rethrowExceptionInPrivateScript(scriptState->i
solate(), exceptionState, block)) { | 391 if (!PrivateScriptRunner::rethrowExceptionInPrivateScript(scriptState->i
solate(), exceptionState, block)) { |
| 401 // FIXME: We should support more exceptions. | 392 // FIXME: We should support more exceptions. |
| 402 RELEASE_ASSERT_NOT_REACHED(); | 393 RELEASE_ASSERT_NOT_REACHED(); |
| 403 } | 394 } |
| 404 block.ReThrow(); | 395 block.ReThrow(); |
| 405 return false; | 396 return false; |
| 406 } | 397 } |
| 407 return true; | 398 return true; |
| 408 } | 399 } |
| 409 {% endmacro %} | 400 {% endmacro %} |
| OLD | NEW |