| OLD | NEW |
| 1 # Copyright (C) 2013 Google Inc. All rights reserved. | 1 # Copyright (C) 2013 Google Inc. All rights reserved. |
| 2 # | 2 # |
| 3 # Redistribution and use in source and binary forms, with or without | 3 # Redistribution and use in source and binary forms, with or without |
| 4 # modification, are permitted provided that the following conditions are | 4 # modification, are permitted provided that the following conditions are |
| 5 # met: | 5 # met: |
| 6 # | 6 # |
| 7 # * Redistributions of source code must retain the above copyright | 7 # * Redistributions of source code must retain the above copyright |
| 8 # notice, this list of conditions and the following disclaimer. | 8 # notice, this list of conditions and the following disclaimer. |
| 9 # * Redistributions in binary form must reproduce the above | 9 # * Redistributions in binary form must reproduce the above |
| 10 # copyright notice, this list of conditions and the following disclaimer | 10 # copyright notice, this list of conditions and the following disclaimer |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 88 interface.name in ['Window', 'WorkerGlobalScope'] and | 88 interface.name in ['Window', 'WorkerGlobalScope'] and |
| 89 attribute.name == 'onerror'): | 89 attribute.name == 'onerror'): |
| 90 includes.add('bindings/core/v8/V8ErrorHandler.h') | 90 includes.add('bindings/core/v8/V8ErrorHandler.h') |
| 91 | 91 |
| 92 cached_attribute_validation_method = extended_attributes.get('CachedAttribut
e') | 92 cached_attribute_validation_method = extended_attributes.get('CachedAttribut
e') |
| 93 keep_alive_for_gc = is_keep_alive_for_gc(interface, attribute) | 93 keep_alive_for_gc = is_keep_alive_for_gc(interface, attribute) |
| 94 if cached_attribute_validation_method or keep_alive_for_gc: | 94 if cached_attribute_validation_method or keep_alive_for_gc: |
| 95 includes.add('bindings/core/v8/V8HiddenValue.h') | 95 includes.add('bindings/core/v8/V8HiddenValue.h') |
| 96 | 96 |
| 97 if 'APIExperimentEnabled' in extended_attributes: | 97 if 'APIExperimentEnabled' in extended_attributes: |
| 98 includes.add('core/experiments/ExperimentalFeatures.h') | |
| 99 includes.add('core/inspector/ConsoleMessage.h') | 98 includes.add('core/inspector/ConsoleMessage.h') |
| 99 includes.add('core/origin_trials/OriginTrials.h') |
| 100 | 100 |
| 101 context = { | 101 context = { |
| 102 'access_control_list': access_control_list(interface, attribute), | 102 'access_control_list': access_control_list(interface, attribute), |
| 103 'activity_logging_world_list_for_getter': v8_utilities.activity_logging_
world_list(attribute, 'Getter'), # [ActivityLogging] | 103 'activity_logging_world_list_for_getter': v8_utilities.activity_logging_
world_list(attribute, 'Getter'), # [ActivityLogging] |
| 104 'activity_logging_world_list_for_setter': v8_utilities.activity_logging_
world_list(attribute, 'Setter'), # [ActivityLogging] | 104 'activity_logging_world_list_for_setter': v8_utilities.activity_logging_
world_list(attribute, 'Setter'), # [ActivityLogging] |
| 105 'activity_logging_world_check': v8_utilities.activity_logging_world_chec
k(attribute), # [ActivityLogging] | 105 'activity_logging_world_check': v8_utilities.activity_logging_world_chec
k(attribute), # [ActivityLogging] |
| 106 'api_experiment_enabled': v8_utilities.api_experiment_enabled_function(a
ttribute), # [APIExperimentEnabled] | 106 'api_experiment_enabled': v8_utilities.api_experiment_enabled_function(a
ttribute), # [APIExperimentEnabled] |
| 107 'api_experiment_enabled_per_interface': v8_utilities.api_experiment_enab
led_function(interface), # [APIExperimentEnabled] | 107 'api_experiment_enabled_per_interface': v8_utilities.api_experiment_enab
led_function(interface), # [APIExperimentEnabled] |
| 108 'api_experiment_name': extended_attributes.get('APIExperimentEnabled'),
# [APIExperimentEnabled] | 108 'api_experiment_name': extended_attributes.get('APIExperimentEnabled'),
# [APIExperimentEnabled] |
| 109 'argument_cpp_type': idl_type.cpp_type_args(used_as_rvalue_type=True), | 109 'argument_cpp_type': idl_type.cpp_type_args(used_as_rvalue_type=True), |
| (...skipping 401 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 511 return attribute.idl_type.name.endswith('Constructor') | 511 return attribute.idl_type.name.endswith('Constructor') |
| 512 | 512 |
| 513 | 513 |
| 514 def update_constructor_attribute_context(interface, attribute, context): | 514 def update_constructor_attribute_context(interface, attribute, context): |
| 515 context['needs_constructor_getter_callback'] = context['measure_as'] or cont
ext['deprecate_as'] or context['api_experiment_name'] | 515 context['needs_constructor_getter_callback'] = context['measure_as'] or cont
ext['deprecate_as'] or context['api_experiment_name'] |
| 516 # When the attribute name is the same as the interface name, do not generate | 516 # When the attribute name is the same as the interface name, do not generate |
| 517 # callback functions for each attribute and use | 517 # callback functions for each attribute and use |
| 518 # {{cpp_class}}ConstructorAttributeSetterCallback. Otherwise, generate | 518 # {{cpp_class}}ConstructorAttributeSetterCallback. Otherwise, generate |
| 519 # a callback function in order to hard-code the attribute name. | 519 # a callback function in order to hard-code the attribute name. |
| 520 context['needs_constructor_setter_callback'] = context['name'] != context['c
onstructor_type'] | 520 context['needs_constructor_setter_callback'] = context['name'] != context['c
onstructor_type'] |
| OLD | NEW |