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

Unified Diff: tools/dom/src/dart2js_Conversions.dart

Issue 13471016: Fixing conversion of null event targets. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 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 | « tests/html/mouse_event_test.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/dom/src/dart2js_Conversions.dart
diff --git a/tools/dom/src/dart2js_Conversions.dart b/tools/dom/src/dart2js_Conversions.dart
index 7e9ee41aaa11b51c96fcb5a961f021fb0fd2db69..8ced5efcaf5c6e5638eeeca0f9802db06cc12fe4 100644
--- a/tools/dom/src/dart2js_Conversions.dart
+++ b/tools/dom/src/dart2js_Conversions.dart
@@ -25,6 +25,9 @@ WindowBase _convertNativeToDart_Window(win) {
}
EventTarget _convertNativeToDart_EventTarget(e) {
+ if (e == null) {
+ return null;
+ }
// Assume it's a Window if it contains the setInterval property. It may be
// from a different frame - without a patched prototype - so we cannot
// rely on Dart type checking.
« no previous file with comments | « tests/html/mouse_event_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698