Changeset 95937 in webkit
- Timestamp:
- Sep 26, 2011 12:21:45 AM (13 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 4 edited
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r95931 r95937 1 2011-09-26 James Robinson <jamesr@chromium.org> 2 3 [mac] Timestamp parameter to requestAnimationFrame is busted in USE(REQUEST_ANIMATION_FRAME_TIMER) path 4 https://bugs.webkit.org/show_bug.cgi?id=68769 5 6 Reviewed by Simon Fraser. 7 8 Adds a test that the timestamp parameter to the requestAnimationFrame callback advances between calls. 9 10 * fast/animation/request-animation-frame-timestamps-advance-expected.txt: Added. 11 * fast/animation/request-animation-frame-timestamps-advance.html: Added. 12 * fast/animation/script-tests/request-animation-frame-timestamps-advance.js: Copied from LayoutTests/fast/animation/script-tests/request-animation-frame-timestamps.js. 13 (busyWait): 14 (window.webkitRequestAnimationFrame): 15 * fast/animation/script-tests/request-animation-frame-timestamps.js: 16 Remove the element parameter, they aren't a useful part of the test. 17 1 18 2011-09-25 Kentaro Hara <haraken@chromium.org> 2 19 -
trunk/LayoutTests/fast/animation/script-tests/request-animation-frame-timestamps-advance.js
r95936 r95937 1 description("Tests the timestamps provided to requestAnimationFrame callbacks ");1 description("Tests the timestamps provided to requestAnimationFrame callbacks advance"); 2 2 3 3 function busyWait(millis) { … … 6 6 } 7 7 8 var e = document.getElementById("e");9 8 var firstTimestamp = undefined; 9 var secondTimestamp = undefined; 10 10 11 11 window.webkitRequestAnimationFrame(function(timestamp) { 12 12 firstTimestamp = timestamp; 13 13 shouldBeDefined("firstTimestamp"); 14 window.webkitRequestAnimationFrame(function(timestamp) { 15 secondTimestamp = timestamp; 16 shouldBeDefined("secondTimestamp"); 17 shouldBeTrue("secondTimestamp > firstTimestamp"); 18 isSuccessfullyParsed(); 19 if (window.layoutTestController) 20 layoutTestController.notifyDone(); 21 }); 14 22 busyWait(10); 15 }, e); 23 if (window.layoutTestController) 24 layoutTestController.display(); 25 }); 16 26 17 var secondTimestamp = undefined;18 window.webkitRequestAnimationFrame(function(timestamp) {19 secondTimestamp = timestamp;20 shouldBeDefined("secondTimestamp");21 shouldBe("firstTimestamp", "secondTimestamp");22 }, e);23 27 24 28 if (window.layoutTestController) 25 layoutTestController.display(); 29 window.setTimeout(function() { 30 layoutTestController.display(); 31 }); 32 26 33 27 34 if (window.layoutTestController) 28 35 layoutTestController.waitUntilDone(); 29 36 30 setTimeout(function() {31 shouldBeDefined("firstTimestamp");32 }, 100);33 34 37 var successfullyParsed = true; 35 36 setTimeout(function() {37 isSuccessfullyParsed();38 if (window.layoutTestController)39 layoutTestController.notifyDone();40 }, 200); -
trunk/LayoutTests/fast/animation/script-tests/request-animation-frame-timestamps.js
r93980 r95937 6 6 } 7 7 8 var e = document.getElementById("e");9 8 var firstTimestamp = undefined; 10 9 … … 13 12 shouldBeDefined("firstTimestamp"); 14 13 busyWait(10); 15 } , e);14 }); 16 15 17 16 var secondTimestamp = undefined; … … 20 19 shouldBeDefined("secondTimestamp"); 21 20 shouldBe("firstTimestamp", "secondTimestamp"); 22 } , e);21 }); 23 22 24 23 if (window.layoutTestController) -
trunk/Source/WebCore/ChangeLog
r95936 r95937 1 2011-09-26 James Robinson <jamesr@chromium.org> 2 3 [mac] Timestamp parameter to requestAnimationFrame is busted in USE(REQUEST_ANIMATION_FRAME_TIMER) path 4 https://bugs.webkit.org/show_bug.cgi?id=68769 5 6 Reviewed by Simon Fraser. 7 8 Convert the time parameter from double to DOMTimeStamp using convertSecondsToDOMTimeStamp rather than relying on 9 implicit double->long conversion, which ignores the units of the value. 10 11 Test: fast/animation/request-animation-frame-timestamps-advance.html 12 13 * dom/ScriptedAnimationController.cpp: 14 (WebCore::ScriptedAnimationController::animationTimerFired): 15 1 16 2011-09-25 Mark Hahnenberg <mhahnenberg@apple.com> 2 17 -
trunk/Source/WebCore/dom/ScriptedAnimationController.cpp
r95901 r95937 162 162 { 163 163 m_lastAnimationFrameTime = currentTime(); 164 serviceScriptedAnimations( m_lastAnimationFrameTime);164 serviceScriptedAnimations(convertSecondsToDOMTimeStamp(m_lastAnimationFrameTime)); 165 165 } 166 166 #endif
Note: See TracChangeset
for help on using the changeset viewer.