Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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 class _EventsImpl implements Events { | 5 class _EventsImpl implements Events { |
| 6 // TODO(podivilov): add type. | 6 // TODO(podivilov): add type. |
| 7 final _ptr; | 7 final _ptr; |
| 8 | 8 |
| 9 final Map<String, EventListenerList> _listenerMap; | 9 final Map<String, EventListenerList> _listenerMap; |
| 10 | 10 |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 97 } | 97 } |
| 98 } | 98 } |
| 99 } | 99 } |
| 100 final wrapped = (e) { listener(_wrap(e)); }; | 100 final wrapped = (e) { listener(_wrap(e)); }; |
| 101 _wrappers.add(new _EventListenerWrapper(listener, wrapped, useCapture)); | 101 _wrappers.add(new _EventListenerWrapper(listener, wrapped, useCapture)); |
| 102 return wrapped; | 102 return wrapped; |
| 103 } | 103 } |
| 104 } | 104 } |
| 105 | 105 |
| 106 class $CLASSNAME$EXTENDS$IMPLEMENTS$NATIVESPEC { | 106 class $CLASSNAME$EXTENDS$IMPLEMENTS$NATIVESPEC { |
| 107 | 107 /* |
|
Anton Muhin
2012/05/30 00:18:47
wow, maybe just remove?
podivilov
2012/05/30 16:02:55
It would break the generation because of $!MEMBERS
| |
| 108 Events _on; | |
| 109 | |
| 110 Events get on() { | |
| 111 if (_on == null) _on = new _EventsImpl(this); | |
| 112 return _on; | |
| 113 } | |
| 114 | |
| 115 $!MEMBERS | 108 $!MEMBERS |
| 109 */ | |
| 116 } | 110 } |
| OLD | NEW |