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

Unified Diff: tools/dom/templates/html/impl/impl_CustomEvent.darttemplate

Issue 18811006: Fixing CustomEvent.detail leaks. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 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 side-by-side diff with in-line comments
Download patch
« sdk/lib/html/dartium/html_dartium.dart ('K') | « tools/dom/scripts/generator.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/dom/templates/html/impl/impl_CustomEvent.darttemplate
diff --git a/tools/dom/templates/html/impl/impl_CustomEvent.darttemplate b/tools/dom/templates/html/impl/impl_CustomEvent.darttemplate
index be6b7ef4852a2876ae20d30c405929082c57c761..a5305e1557bfda1edfecdcfdbc2675e00a3724cd 100644
--- a/tools/dom/templates/html/impl/impl_CustomEvent.darttemplate
+++ b/tools/dom/templates/html/impl/impl_CustomEvent.darttemplate
@@ -10,7 +10,11 @@ $(ANNOTATIONS)$(CLASS_MODIFIERS)class $CLASSNAME$EXTENDS$IMPLEMENTS$NATIVESPEC {
factory $CLASSNAME(String type,
{bool canBubble: true, bool cancelable: true, Object detail}) {
- final CustomEvent e = document.$dom_createEvent("CustomEvent");
+ final CustomEvent e = document.$dom_createEvent('CustomEvent');
+
+$if DART2JS
+ detail = convertDartToNative_SerializedScriptValue(detail);
+$endif
e.$dom_initCustomEvent(type, canBubble, cancelable, detail);
return e;
« sdk/lib/html/dartium/html_dartium.dart ('K') | « tools/dom/scripts/generator.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698