| 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 294 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 305 | 305 |
| 306 if constructors or custom_constructors or has_html_constructor or named_cons
tructor: | 306 if constructors or custom_constructors or has_html_constructor or named_cons
tructor: |
| 307 if interface.is_partial: | 307 if interface.is_partial: |
| 308 raise Exception('[Constructor] and [NamedConstructor] MUST NOT be' | 308 raise Exception('[Constructor] and [NamedConstructor] MUST NOT be' |
| 309 ' specified on partial interface definitions: ' | 309 ' specified on partial interface definitions: ' |
| 310 '%s' % interface.name) | 310 '%s' % interface.name) |
| 311 | 311 |
| 312 includes.add('bindings/core/v8/V8ObjectConstructor.h') | 312 includes.add('bindings/core/v8/V8ObjectConstructor.h') |
| 313 includes.add('core/frame/LocalDOMWindow.h') | 313 includes.add('core/frame/LocalDOMWindow.h') |
| 314 elif 'Measure' in extended_attributes or 'MeasureAs' in extended_attributes: | 314 elif 'Measure' in extended_attributes or 'MeasureAs' in extended_attributes: |
| 315 raise Exception('[Measure] or [MeasureAs] specified for interface withou
t a constructor: ' | 315 if not interface.is_partial: |
| 316 '%s' % interface.name) | 316 raise Exception('[Measure] or [MeasureAs] specified for interface wi
thout a constructor: ' |
| 317 '%s' % interface.name) |
| 317 | 318 |
| 318 # [Unscopable] attributes and methods | 319 # [Unscopable] attributes and methods |
| 319 unscopables = [] | 320 unscopables = [] |
| 320 for attribute in interface.attributes: | 321 for attribute in interface.attributes: |
| 321 if 'Unscopable' in attribute.extended_attributes: | 322 if 'Unscopable' in attribute.extended_attributes: |
| 322 unscopables.append((attribute.name, v8_utilities.runtime_enabled_fun
ction_name(attribute))) | 323 unscopables.append((attribute.name, v8_utilities.runtime_enabled_fun
ction_name(attribute))) |
| 323 for method in interface.operations: | 324 for method in interface.operations: |
| 324 if 'Unscopable' in method.extended_attributes: | 325 if 'Unscopable' in method.extended_attributes: |
| 325 unscopables.append((method.name, v8_utilities.runtime_enabled_functi
on_name(method))) | 326 unscopables.append((method.name, v8_utilities.runtime_enabled_functi
on_name(method))) |
| 326 | 327 |
| (...skipping 1102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1429 extended_attributes = deleter.extended_attributes | 1430 extended_attributes = deleter.extended_attributes |
| 1430 is_call_with_script_state = v8_utilities.has_extended_attribute_value(delete
r, 'CallWith', 'ScriptState') | 1431 is_call_with_script_state = v8_utilities.has_extended_attribute_value(delete
r, 'CallWith', 'ScriptState') |
| 1431 is_ce_reactions = 'CEReactions' in extended_attributes | 1432 is_ce_reactions = 'CEReactions' in extended_attributes |
| 1432 return { | 1433 return { |
| 1433 'is_call_with_script_state': is_call_with_script_state, | 1434 'is_call_with_script_state': is_call_with_script_state, |
| 1434 'is_ce_reactions': is_ce_reactions, | 1435 'is_ce_reactions': is_ce_reactions, |
| 1435 'is_custom': 'Custom' in extended_attributes, | 1436 'is_custom': 'Custom' in extended_attributes, |
| 1436 'is_raises_exception': 'RaisesException' in extended_attributes, | 1437 'is_raises_exception': 'RaisesException' in extended_attributes, |
| 1437 'name': cpp_name(deleter), | 1438 'name': cpp_name(deleter), |
| 1438 } | 1439 } |
| OLD | NEW |