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/templates/html/impl/impl_Window.darttemplate

Issue 2893893002: Use generic functions in zones. (Closed)
Patch Set: Fix more tests. Created 3 years, 4 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
« no previous file with comments | « tools/dom/src/shared_html.dart ('k') | tools/testing/dart/test_runner.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 // 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 part of $LIBRARYNAME; 5 part of $LIBRARYNAME;
6 6
7 @DocsEditable() 7 @DocsEditable()
8 $(ANNOTATIONS)@Native("Window,DOMWindow") 8 $(ANNOTATIONS)@Native("Window,DOMWindow")
9 $(CLASS_MODIFIERS)class $CLASSNAME$EXTENDS$IMPLEMENTS { 9 $(CLASS_MODIFIERS)class $CLASSNAME$EXTENDS$IMPLEMENTS {
10 10
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 * request. This value only needs to be saved if you intend to call 103 * request. This value only needs to be saved if you intend to call
104 * [cancelAnimationFrame] so you can specify the particular animation to 104 * [cancelAnimationFrame] so you can specify the particular animation to
105 * cancel. 105 * cancel.
106 * 106 *
107 * Note: The supplied [callback] needs to call [requestAnimationFrame] again 107 * Note: The supplied [callback] needs to call [requestAnimationFrame] again
108 * for the animation to continue. 108 * for the animation to continue.
109 */ 109 */
110 @DomName('Window.requestAnimationFrame') 110 @DomName('Window.requestAnimationFrame')
111 int requestAnimationFrame(FrameRequestCallback callback) { 111 int requestAnimationFrame(FrameRequestCallback callback) {
112 _ensureRequestAnimationFrame(); 112 _ensureRequestAnimationFrame();
113 return _requestAnimationFrame(_wrapZone/*<num, dynamic>*/(callback)); 113 return _requestAnimationFrame(_wrapZone(callback));
114 } 114 }
115 115
116 /** 116 /**
117 * Cancels an animation frame request. 117 * Cancels an animation frame request.
118 * 118 *
119 * ## Other resources 119 * ## Other resources
120 * 120 *
121 * * [Window.cancelAnimationFrame](https://developer.mozilla.org/en-US/docs/We b/API/Window.cancelAnimationFrame) 121 * * [Window.cancelAnimationFrame](https://developer.mozilla.org/en-US/docs/We b/API/Window.cancelAnimationFrame)
122 * from MDN. 122 * from MDN.
123 */ 123 */
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
312 // Specify the generic type for _ElementEventStreamImpl only in dart2js. 312 // Specify the generic type for _ElementEventStreamImpl only in dart2js.
313 return new _ElementEventStreamImpl<BeforeUnloadEvent>(e, _eventType, useCapt ure); 313 return new _ElementEventStreamImpl<BeforeUnloadEvent>(e, _eventType, useCapt ure);
314 } 314 }
315 315
316 ElementStream<BeforeUnloadEvent> _forElementList(ElementList e, 316 ElementStream<BeforeUnloadEvent> _forElementList(ElementList e,
317 {bool useCapture: false}) { 317 {bool useCapture: false}) {
318 // Specify the generic type for _ElementEventStreamImpl only in dart2js. 318 // Specify the generic type for _ElementEventStreamImpl only in dart2js.
319 return new _ElementListEventStreamImpl<BeforeUnloadEvent>(e, _eventType, use Capture); 319 return new _ElementListEventStreamImpl<BeforeUnloadEvent>(e, _eventType, use Capture);
320 } 320 }
321 } 321 }
OLDNEW
« no previous file with comments | « tools/dom/src/shared_html.dart ('k') | tools/testing/dart/test_runner.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698