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

Side by Side Diff: tools/dom/src/dart2js_KeyEvent.dart

Issue 12493003: Exposing Point & Rect types (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Sync to ToT 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « tools/dom/src/Rectangle.dart ('k') | tools/dom/src/dartium_KeyEvent.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /** 1 /**
2 * A custom KeyboardEvent that attempts to eliminate cross-browser 2 * A custom KeyboardEvent that attempts to eliminate cross-browser
3 * inconsistencies, and also provide both keyCode and charCode information 3 * inconsistencies, and also provide both keyCode and charCode information
4 * for all key events (when such information can be determined). 4 * for all key events (when such information can be determined).
5 * 5 *
6 * This class is very much a work in progress, and we'd love to get information 6 * This class is very much a work in progress, and we'd love to get information
7 * on how we can make this class work with as many international keyboards as 7 * on how we can make this class work with as many international keyboards as
8 * possible. Bugs welcome! 8 * possible. Bugs welcome!
9 */ 9 */
10 class KeyEvent implements KeyboardEvent { 10 class KeyEvent implements KeyboardEvent {
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 EventTarget get currentTarget => _parent.currentTarget; 66 EventTarget get currentTarget => _parent.currentTarget;
67 bool get defaultPrevented => _parent.defaultPrevented; 67 bool get defaultPrevented => _parent.defaultPrevented;
68 int get detail => _parent.detail; 68 int get detail => _parent.detail;
69 int get eventPhase => _parent.eventPhase; 69 int get eventPhase => _parent.eventPhase;
70 /** 70 /**
71 * Accessor to the part of the keyboard that the key was pressed from (one of 71 * Accessor to the part of the keyboard that the key was pressed from (one of
72 * KeyLocation.STANDARD, KeyLocation.RIGHT, KeyLocation.LEFT, 72 * KeyLocation.STANDARD, KeyLocation.RIGHT, KeyLocation.LEFT,
73 * KeyLocation.NUMPAD, KeyLocation.MOBILE, KeyLocation.JOYSTICK). 73 * KeyLocation.NUMPAD, KeyLocation.MOBILE, KeyLocation.JOYSTICK).
74 */ 74 */
75 int get keyLocation => _parent.keyLocation; 75 int get keyLocation => _parent.keyLocation;
76 int get layerX => _parent.layerX; 76 Point get layer => _parent.layer;
77 int get layerY => _parent.layerY;
78 /** True if the Meta (or Mac command) key is pressed during this event. */ 77 /** True if the Meta (or Mac command) key is pressed during this event. */
79 bool get metaKey => _parent.metaKey; 78 bool get metaKey => _parent.metaKey;
80 int get pageX => _parent.pageX; 79 Point get page => _parent.page;
81 int get pageY => _parent.pageY;
82 bool get returnValue => _parent.returnValue; 80 bool get returnValue => _parent.returnValue;
83 void set returnValue(bool value) { 81 void set returnValue(bool value) {
84 _parent.returnValue = value; 82 _parent.returnValue = value;
85 } 83 }
86 /** True if the shift key was pressed during this event. */ 84 /** True if the shift key was pressed during this event. */
87 bool get shiftKey => _parent.shiftKey; 85 bool get shiftKey => _parent.shiftKey;
88 int get timeStamp => _parent.timeStamp; 86 int get timeStamp => _parent.timeStamp;
89 /** 87 /**
90 * The type of key event that occurred. One of "keydown", "keyup", or 88 * The type of key event that occurred. One of "keydown", "keyup", or
91 * "keypress". 89 * "keypress".
(...skipping 20 matching lines...) Expand all
112 throw new UnsupportedError("keyIdentifier is unsupported."); 110 throw new UnsupportedError("keyIdentifier is unsupported.");
113 } 111 }
114 void $dom_initKeyboardEvent(String type, bool canBubble, bool cancelable, 112 void $dom_initKeyboardEvent(String type, bool canBubble, bool cancelable,
115 Window view, String keyIdentifier, int keyLocation, bool ctrlKey, 113 Window view, String keyIdentifier, int keyLocation, bool ctrlKey,
116 bool altKey, bool shiftKey, bool metaKey, 114 bool altKey, bool shiftKey, bool metaKey,
117 bool altGraphKey) { 115 bool altGraphKey) {
118 throw new UnsupportedError( 116 throw new UnsupportedError(
119 "Cannot initialize a KeyboardEvent from a KeyEvent."); 117 "Cannot initialize a KeyboardEvent from a KeyEvent.");
120 } 118 }
121 } 119 }
OLDNEW
« no previous file with comments | « tools/dom/src/Rectangle.dart ('k') | tools/dom/src/dartium_KeyEvent.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698