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

Unified Diff: sdk/lib/html/dart2js/html_dart2js.dart

Side-by-side diff isn't available for this file because of its large size.
Issue 12061004: Updating KeyboardEvent constructor to use named parameters. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 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:
Download patch
« no previous file with comments | « no previous file | sdk/lib/html/dartium/html_dartium.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/html/dart2js/html_dart2js.dart
diff --git a/sdk/lib/html/dart2js/html_dart2js.dart b/sdk/lib/html/dart2js/html_dart2js.dart
index 3171ff58d9c02c24b9b32343fbc4741388a84057..24a1687c86d457884432f051bb36f241be7f74ef 100644
--- a/sdk/lib/html/dart2js/html_dart2js.dart
+++ b/sdk/lib/html/dart2js/html_dart2js.dart
@@ -14602,11 +14602,14 @@ class JavaScriptCallFrame native "*JavaScriptCallFrame" {
@DomName('KeyboardEvent')
class KeyboardEvent extends UIEvent native "*KeyboardEvent" {
- factory KeyboardEvent(String type, Window view,
- [bool canBubble = true, bool cancelable = true,
- String keyIdentifier = "", int keyLocation = 1, bool ctrlKey = false,
- bool altKey = false, bool shiftKey = false, bool metaKey = false,
- bool altGraphKey = false]) {
+ factory KeyboardEvent(String type,
+ {Window view, bool canBubble: true, bool cancelable: true,
+ String keyIdentifier: "", int keyLocation: 1, bool ctrlKey: false,
+ bool altKey: false, bool shiftKey: false, bool metaKey: false,
+ bool altGraphKey: false}) {
+ if (view == null) {
+ view = window;
+ }
final e = document.$dom_createEvent("KeyboardEvent");
e.$dom_initKeyboardEvent(type, canBubble, cancelable, view, keyIdentifier,
keyLocation, ctrlKey, altKey, shiftKey, metaKey, altGraphKey);
« no previous file with comments | « no previous file | sdk/lib/html/dartium/html_dartium.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698