| OLD | NEW |
| 1 # Copyright (C) 2013 Google Inc. All rights reserved. | 1 # Copyright (C) 2013 Google Inc. All rights reserved. |
| 2 # coding=utf-8 | 2 # coding=utf-8 |
| 3 # | 3 # |
| 4 # Redistribution and use in source and binary forms, with or without | 4 # Redistribution and use in source and binary forms, with or without |
| 5 # modification, are permitted provided that the following conditions are | 5 # modification, are permitted provided that the following conditions are |
| 6 # met: | 6 # met: |
| 7 # | 7 # |
| 8 # * Redistributions of source code must retain the above copyright | 8 # * Redistributions of source code must retain the above copyright |
| 9 # notice, this list of conditions and the following disclaimer. | 9 # notice, this list of conditions and the following disclaimer. |
| 10 # * Redistributions in binary form must reproduce the above | 10 # * Redistributions in binary form must reproduce the above |
| (...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 383 | 383 |
| 384 # Conditionally enabled members | 384 # Conditionally enabled members |
| 385 has_conditional_attributes_on_prototype = any( # pylint: disable=invalid-na
me | 385 has_conditional_attributes_on_prototype = any( # pylint: disable=invalid-na
me |
| 386 (attribute['exposed_test'] or attribute['secure_context_test']) and attr
ibute['on_prototype'] | 386 (attribute['exposed_test'] or attribute['secure_context_test']) and attr
ibute['on_prototype'] |
| 387 for attribute in attributes) | 387 for attribute in attributes) |
| 388 context.update({ | 388 context.update({ |
| 389 'has_conditional_attributes_on_prototype': | 389 'has_conditional_attributes_on_prototype': |
| 390 has_conditional_attributes_on_prototype, | 390 has_conditional_attributes_on_prototype, |
| 391 }) | 391 }) |
| 392 | 392 |
| 393 prepare_prototype_and_interface_object_func = None # pylint: disable=invali
d-name |
| 394 if (unscopables or has_conditional_attributes_on_prototype or |
| 395 v8_methods.filter_conditionally_exposed(methods, interface.is_partia
l)): |
| 396 prepare_prototype_and_interface_object_func = '%s::preparePrototypeAndIn
terfaceObject' % v8_class_name_or_partial # pylint: disable=invalid-name |
| 397 |
| 398 context.update({ |
| 399 'prepare_prototype_and_interface_object_func': prepare_prototype_and_int
erface_object_func, |
| 400 }) |
| 401 |
| 393 context.update({ | 402 context.update({ |
| 394 'legacy_caller': legacy_caller(interface.legacy_caller, interface), | 403 'legacy_caller': legacy_caller(interface.legacy_caller, interface), |
| 395 'indexed_property_getter': property_getter(interface.indexed_property_ge
tter, ['index']), | 404 'indexed_property_getter': property_getter(interface.indexed_property_ge
tter, ['index']), |
| 396 'indexed_property_setter': property_setter(interface.indexed_property_se
tter, interface), | 405 'indexed_property_setter': property_setter(interface.indexed_property_se
tter, interface), |
| 397 'indexed_property_deleter': property_deleter(interface.indexed_property_
deleter), | 406 'indexed_property_deleter': property_deleter(interface.indexed_property_
deleter), |
| 398 'is_override_builtins': 'OverrideBuiltins' in extended_attributes, | 407 'is_override_builtins': 'OverrideBuiltins' in extended_attributes, |
| 399 'named_property_getter': property_getter(interface.named_property_getter
, ['name']), | 408 'named_property_getter': property_getter(interface.named_property_getter
, ['name']), |
| 400 'named_property_setter': property_setter(interface.named_property_setter
, interface), | 409 'named_property_setter': property_setter(interface.named_property_setter
, interface), |
| 401 'named_property_deleter': property_deleter(interface.named_property_dele
ter), | 410 'named_property_deleter': property_deleter(interface.named_property_dele
ter), |
| 402 }) | 411 }) |
| (...skipping 957 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1360 extended_attributes = deleter.extended_attributes | 1369 extended_attributes = deleter.extended_attributes |
| 1361 is_call_with_script_state = v8_utilities.has_extended_attribute_value(delete
r, 'CallWith', 'ScriptState') | 1370 is_call_with_script_state = v8_utilities.has_extended_attribute_value(delete
r, 'CallWith', 'ScriptState') |
| 1362 is_ce_reactions = 'CEReactions' in extended_attributes | 1371 is_ce_reactions = 'CEReactions' in extended_attributes |
| 1363 return { | 1372 return { |
| 1364 'is_call_with_script_state': is_call_with_script_state, | 1373 'is_call_with_script_state': is_call_with_script_state, |
| 1365 'is_ce_reactions': is_ce_reactions, | 1374 'is_ce_reactions': is_ce_reactions, |
| 1366 'is_custom': 'Custom' in extended_attributes, | 1375 'is_custom': 'Custom' in extended_attributes, |
| 1367 'is_raises_exception': 'RaisesException' in extended_attributes, | 1376 'is_raises_exception': 'RaisesException' in extended_attributes, |
| 1368 'name': cpp_name(deleter), | 1377 'name': cpp_name(deleter), |
| 1369 } | 1378 } |
| OLD | NEW |