OLD | NEW |
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 part of dart.html; | 5 part of dart.html; |
6 | 6 |
7 /** | 7 /** |
8 * Helper class to implement custom events which wrap DOM events. | 8 * Helper class to implement custom events which wrap DOM events. |
9 */ | 9 */ |
10 class _WrappedEvent implements Event { | 10 class _WrappedEvent implements Event { |
11 final Event wrapped; | 11 final Event wrapped; |
12 _WrappedEvent(this.wrapped); | 12 _WrappedEvent(this.wrapped); |
13 | 13 |
14 bool get bubbles => wrapped.bubbles; | 14 bool get bubbles => wrapped.bubbles; |
15 | 15 |
16 bool get cancelBubble => wrapped.bubbles; | |
17 void set cancelBubble(bool value) { | |
18 wrapped.cancelBubble = value; | |
19 } | |
20 | |
21 bool get cancelable => wrapped.cancelable; | 16 bool get cancelable => wrapped.cancelable; |
22 | 17 |
23 DataTransfer get clipboardData => wrapped.clipboardData; | 18 DataTransfer get clipboardData => wrapped.clipboardData; |
24 | 19 |
25 EventTarget get currentTarget => wrapped.currentTarget; | 20 EventTarget get currentTarget => wrapped.currentTarget; |
26 | 21 |
27 bool get defaultPrevented => wrapped.defaultPrevented; | 22 bool get defaultPrevented => wrapped.defaultPrevented; |
28 | 23 |
29 int get eventPhase => wrapped.eventPhase; | 24 int get eventPhase => wrapped.eventPhase; |
30 | 25 |
(...skipping 14 matching lines...) Expand all Loading... |
45 } | 40 } |
46 | 41 |
47 void stopImmediatePropagation() { | 42 void stopImmediatePropagation() { |
48 wrapped.stopImmediatePropagation(); | 43 wrapped.stopImmediatePropagation(); |
49 } | 44 } |
50 | 45 |
51 void stopPropagation() { | 46 void stopPropagation() { |
52 wrapped.stopPropagation(); | 47 wrapped.stopPropagation(); |
53 } | 48 } |
54 } | 49 } |
OLD | NEW |