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

Unified Diff: sky/engine/bindings/scripts/dart_types.py

Issue 1151673002: Sky: different tack for custom Rect type in the Canvas API. (Closed) Base URL: git@github.com:/domokit/mojo.git@master
Patch Set: Float32List Created 5 years, 7 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
Index: sky/engine/bindings/scripts/dart_types.py
diff --git a/sky/engine/bindings/scripts/dart_types.py b/sky/engine/bindings/scripts/dart_types.py
index 83335aa40ed1acfc46735c3b18dc023e3aeb4cbb..2a063b87a59b9bcdc8a8ba7c7beead79be6f7ca1 100644
--- a/sky/engine/bindings/scripts/dart_types.py
+++ b/sky/engine/bindings/scripts/dart_types.py
@@ -114,6 +114,7 @@ CPP_SPECIAL_CONVERSION_RULES = {
'boolean': 'bool',
'unrestricted double': 'double',
'unrestricted float': 'float',
+ 'Rect': 'Rect', # Pass Rect by value, not pointer.
}
@@ -352,6 +353,7 @@ DART_TO_CPP_VALUE = {
# FIXME(vsm): This is an enum type (defined in StorageQuota.idl).
# We should handle it automatically, but map to a String for now.
'StorageType': 'DartUtilities::dartToString(args, {index}, exception, {auto_scope})',
+ 'Rect': 'DartConverter<{implemented_as}>::FromArguments{null_check}(args, {index}, exception)',
}
« no previous file with comments | « sky/engine/bindings/scripts/code_generator_dart.py ('k') | sky/engine/bindings/scripts/templates/dart_blink.template » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698