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

Unified Diff: tools/dom/scripts/generator.py

Issue 1583773003: Support JS$ prefix for dart and fix bug where _operator_getter and the [] operator were used incons… (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: remove tests to put with matching dart2js tests Created 4 years, 11 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 | « tests/lib/analyzer/analyze_library.status ('k') | tools/dom/scripts/systemhtml.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/dom/scripts/generator.py
diff --git a/tools/dom/scripts/generator.py b/tools/dom/scripts/generator.py
index 92a5ed0e98c37a40eeb851c0f296c0f82f14b83c..6d235b816f53147a6f71e835d90876aa976dcb45 100644
--- a/tools/dom/scripts/generator.py
+++ b/tools/dom/scripts/generator.py
@@ -546,14 +546,10 @@ class OperationInfo(object):
if (wrap_unwrap_type_blink(type_id, type_registry)):
type_is_callback = self.isCallback(type_registry, type_id)
if (dart_js_interop and type_id == 'EventListener' and
- (self.name == 'addEventListener')):
+ self.name in ['addEventListener', 'removeEventListener']):
# Events fired need use a JsFunction not a anonymous closure to
# insure the event can really be removed.
- parameters.append('wrap_event_listener(this, %s)' % p.name)
- elif (dart_js_interop and type_id == 'EventListener' and
- (self.name == 'removeEventListener')):
- # Find the JsFunction that corresponds to this Dart function.
- parameters.append('_knownListeners[this.hashCode][identityHashCode(%s)]' % p.name)
+ parameters.append('unwrap_jso(js.allowInterop(%s))' % p.name)
elif dart_js_interop and type_id == 'FontFaceSetForEachCallback':
# forEach is supported in the DOM for FontFaceSet as it iterates
# over the Javascript Object the callback parameters are also
« no previous file with comments | « tests/lib/analyzer/analyze_library.status ('k') | tools/dom/scripts/systemhtml.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698