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

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

Issue 337343002: IDL: make optional arguments (without default) explicit sometimes Base URL: https://chromium.googlesource.com/chromium/blink.git@idl-default-arguments-next
Patch Set: Created 6 years, 4 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 | « Source/bindings/scripts/v8_methods.py ('k') | 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_types.py
diff --git a/Source/bindings/scripts/v8_types.py b/Source/bindings/scripts/v8_types.py
index 0b242a87624ae2b90fbad7cb90607bbf5974ff15..f79e8c938b2ca029f39afb287015ca6f56310000 100644
--- a/Source/bindings/scripts/v8_types.py
+++ b/Source/bindings/scripts/v8_types.py
@@ -180,6 +180,10 @@ def cpp_type(idl_type, extended_attributes=None, raw_type=False, used_as_rvalue_
return 'String'
return 'V8StringResource<%s>' % string_mode()
+ if idl_type.is_callback_interface:
+ ptr_type = 'RefPtr' if base_idl_type == 'EventListener' else 'OwnPtr'
+ return cpp_template_type(ptr_type, base_idl_type)
+
if idl_type.is_typed_array_element_type and raw_type:
return base_idl_type + '*'
if idl_type.is_interface_type:
« no previous file with comments | « Source/bindings/scripts/v8_methods.py ('k') | Source/bindings/templates/methods.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698