Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(234)

Side by Side Diff: Source/bindings/scripts/v8_methods.py

Issue 1233483002: Add counters for add/removeEventListener() called with one argument (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: No [Conditional] support Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 110
111 is_check_security_for_frame = ( 111 is_check_security_for_frame = (
112 has_extended_attribute_value(interface, 'CheckSecurity', 'Frame') and 112 has_extended_attribute_value(interface, 'CheckSecurity', 'Frame') and
113 not is_do_not_check_security) 113 not is_do_not_check_security)
114 114
115 is_check_security_for_window = ( 115 is_check_security_for_window = (
116 has_extended_attribute_value(interface, 'CheckSecurity', 'Window') and 116 has_extended_attribute_value(interface, 'CheckSecurity', 'Window') and
117 not is_do_not_check_security) 117 not is_do_not_check_security)
118 118
119 is_raises_exception = 'RaisesException' in extended_attributes 119 is_raises_exception = 'RaisesException' in extended_attributes
120 is_custom_call_prologue = has_extended_attribute_value(method, 'Custom', 'Ca llPrologue')
120 is_custom_call_epilogue = has_extended_attribute_value(method, 'Custom', 'Ca llEpilogue') 121 is_custom_call_epilogue = has_extended_attribute_value(method, 'Custom', 'Ca llEpilogue')
121 is_post_message = 'PostMessage' in extended_attributes 122 is_post_message = 'PostMessage' in extended_attributes
122 if is_post_message: 123 if is_post_message:
123 includes.add('bindings/core/v8/SerializedScriptValueFactory.h') 124 includes.add('bindings/core/v8/SerializedScriptValueFactory.h')
124 includes.add('core/dom/DOMArrayBuffer.h') 125 includes.add('core/dom/DOMArrayBuffer.h')
125 includes.add('core/dom/MessagePort.h') 126 includes.add('core/dom/MessagePort.h')
126 127
127 if 'LenientThis' in extended_attributes: 128 if 'LenientThis' in extended_attributes:
128 raise Exception('[LenientThis] is not supported for operations.') 129 raise Exception('[LenientThis] is not supported for operations.')
129 130
(...skipping 27 matching lines...) Expand all
157 if (argument.idl_type.name == 'SerializedScriptValue' or 158 if (argument.idl_type.name == 'SerializedScriptValue' or
158 argument_conversion_needs_exception_state(method, argument)) ), 159 argument_conversion_needs_exception_state(method, argument)) ),
159 'idl_type': idl_type.base_type, 160 'idl_type': idl_type.base_type,
160 'is_call_with_execution_context': has_extended_attribute_value(method, ' CallWith', 'ExecutionContext'), 161 'is_call_with_execution_context': has_extended_attribute_value(method, ' CallWith', 'ExecutionContext'),
161 'is_call_with_script_arguments': is_call_with_script_arguments, 162 'is_call_with_script_arguments': is_call_with_script_arguments,
162 'is_call_with_script_state': is_call_with_script_state, 163 'is_call_with_script_state': is_call_with_script_state,
163 'is_call_with_this_value': is_call_with_this_value, 164 'is_call_with_this_value': is_call_with_this_value,
164 'is_check_security_for_frame': is_check_security_for_frame, 165 'is_check_security_for_frame': is_check_security_for_frame,
165 'is_check_security_for_node': is_check_security_for_node, 166 'is_check_security_for_node': is_check_security_for_node,
166 'is_check_security_for_window': is_check_security_for_window, 167 'is_check_security_for_window': is_check_security_for_window,
167 'is_custom': 'Custom' in extended_attributes and not is_custom_call_epil ogue, 168 'is_custom': 'Custom' in extended_attributes and
169 not (is_custom_call_prologue or is_custom_call_epilogue),
170 'is_custom_call_prologue': is_custom_call_prologue,
168 'is_custom_call_epilogue': is_custom_call_epilogue, 171 'is_custom_call_epilogue': is_custom_call_epilogue,
169 'is_custom_element_callbacks': is_custom_element_callbacks, 172 'is_custom_element_callbacks': is_custom_element_callbacks,
170 'is_do_not_check_security': is_do_not_check_security, 173 'is_do_not_check_security': is_do_not_check_security,
171 'is_do_not_check_signature': 'DoNotCheckSignature' in extended_attribute s, 174 'is_do_not_check_signature': 'DoNotCheckSignature' in extended_attribute s,
172 'is_explicit_nullable': idl_type.is_explicit_nullable, 175 'is_explicit_nullable': idl_type.is_explicit_nullable,
173 'is_implemented_in_private_script': is_implemented_in_private_script, 176 'is_implemented_in_private_script': is_implemented_in_private_script,
174 'is_partial_interface_member': 177 'is_partial_interface_member':
175 'PartialInterfaceImplementedAs' in extended_attributes, 178 'PartialInterfaceImplementedAs' in extended_attributes,
176 'is_per_world_bindings': 'PerWorldBindings' in extended_attributes, 179 'is_per_world_bindings': 'PerWorldBindings' in extended_attributes,
177 'is_post_message': is_post_message, 180 'is_post_message': is_post_message,
(...skipping 293 matching lines...) Expand 10 before | Expand all | Expand 10 after
471 return method.idl_type and method.idl_type.name == 'Promise' 474 return method.idl_type and method.idl_type.name == 'Promise'
472 475
473 IdlOperation.returns_promise = property(method_returns_promise) 476 IdlOperation.returns_promise = property(method_returns_promise)
474 477
475 478
476 def argument_conversion_needs_exception_state(method, argument): 479 def argument_conversion_needs_exception_state(method, argument):
477 idl_type = argument.idl_type 480 idl_type = argument.idl_type
478 return (idl_type.v8_conversion_needs_exception_state or 481 return (idl_type.v8_conversion_needs_exception_state or
479 argument.is_variadic or 482 argument.is_variadic or
480 (method.returns_promise and idl_type.is_string_type)) 483 (method.returns_promise and idl_type.is_string_type))
OLDNEW
« no previous file with comments | « Source/bindings/core/v8/custom/V8EventTargetCustom.cpp ('k') | Source/bindings/templates/interface.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698