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

Unified Diff: Source/bindings/scripts/v8_methods.py

Issue 203143002: Simplify EventTarget bindings generation (2) (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Add test Created 6 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/bindings/templates/methods.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/scripts/v8_methods.py
diff --git a/Source/bindings/scripts/v8_methods.py b/Source/bindings/scripts/v8_methods.py
index 066b998bd762c2bb0f8dca9a5eee397780b75bd1..e76e818c39baa0434dfc7af612adc2948dc14de6 100644
--- a/Source/bindings/scripts/v8_methods.py
+++ b/Source/bindings/scripts/v8_methods.py
@@ -172,6 +172,13 @@ def generate_argument(interface, method, argument, index):
def cpp_value(interface, method, number_of_arguments):
def cpp_argument(argument):
idl_type = argument.idl_type
+ if idl_type.name == 'EventListener':
+ if (interface.name == 'EventTarget' and
+ method.name == 'removeEventListener'):
+ # FIXME: remove this special case by moving get() into
+ # EventTarget::removeEventListener
+ return '%s.get()' % argument.name
+ return argument.name
if (idl_type.is_callback_interface or
idl_type.name in ['NodeFilter', 'XPathNSResolver']):
# FIXME: remove this special case
« no previous file with comments | « no previous file | Source/bindings/templates/methods.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698