Baseline Widely available
window.cancelAnimationFrame()
ë©ìëë ì´ì ì window.requestAnimationFrame()
ì í¸ì¶íì¬ ì¤ì¼ì¤ë ì ëë©ì´ì
íë ì ìì²ì ì·¨ìí©ëë¤.
window.cancelAnimationFrame(requestID);
Parameters
requestID
ìì²ë ì½ë°± window.requestAnimationFrame()
ì í¸ì¶íì¬ ë°íë ID ê°.
var requestAnimationFrame =
window.requestAnimationFrame ||
window.mozRequestAnimationFrame ||
window.webkitRequestAnimationFrame ||
window.msRequestAnimationFrame;
var cancelAnimationFrame =
window.cancelAnimationFrame || window.mozCancelAnimationFrame;
var start = window.mozAnimationStartTime; // Firefox ììë§ ì§ìë¨. ë¤ë¥¸ ë¸ë¼ì°ì ììë Date.now() ê°ì ê²ì ì¬ì©í ì ìì.
var myReq;
function step(timestamp) {
var progress = timestamp - start;
d.style.left = Math.min(progress / 10, 200) + "px";
if (progress < 2000) {
myReq = requestAnimationFrame(step);
}
}
myReq = requestAnimationFrame(step);
cancelAnimationFrame(myReq);
ë¸ë¼ì°ì í¸íì± ëª
ì¸ í¨ê» 보기
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4