| Index: lib/dom/templates/dom/frog/impl_DOMWindow.darttemplate
|
| diff --git a/lib/dom/templates/dom/frog/impl_DOMWindow.darttemplate b/lib/dom/templates/dom/frog/impl_DOMWindow.darttemplate
|
| index 14f8d9a7aea19978140a12f97bd33419aba53186..400ffa753aab0f799cdae7a56754ace7e99c0820 100644
|
| --- a/lib/dom/templates/dom/frog/impl_DOMWindow.darttemplate
|
| +++ b/lib/dom/templates/dom/frog/impl_DOMWindow.darttemplate
|
| @@ -3,10 +3,26 @@
|
| // BSD-style license that can be found in the LICENSE file.
|
|
|
| class $CLASSNAME$EXTENDS$IMPLEMENTS$NATIVESPEC {
|
| -$!MEMBERS
|
|
|
| Window get _top() native "return this.top;";
|
|
|
| // Override top to return secure wrapper.
|
| Window get top() => _DOMWindowCrossFrameImpl._createSafe(_top);
|
| +
|
| + int requestAnimationFrame(RequestAnimationFrameCallback callback) native '''
|
| + if (!window.requestAnimationFrame) {
|
| + window.requestAnimationFrame =
|
| + window.webkitRequestAnimationFrame ||
|
| + window.mozRequestAnimationFrame ||
|
| + window.msRequestAnimationFrame ||
|
| + window.oRequestAnimationFrame ||
|
| + function (callback) { window.setTimeout(callback, 1000/60); };
|
| + }
|
| + return window.requestAnimationFrame(callback);
|
| +''';
|
| +
|
| + // Protect member 'requestAnimationFrame'.
|
| + _requestAnimationFrame() native 'requestAnimationFrame';
|
| +
|
| +$!MEMBERS
|
| }
|
|
|