| OLD | NEW |
| 1 <html> | 1 <html> |
| 2 <head> | 2 <head> |
| 3 <script src="../../http/tests/inspector/inspector-test.js"></script> | 3 <script src="../../http/tests/inspector/inspector-test.js"></script> |
| 4 <script src="../../http/tests/inspector/timeline-test.js"></script> | 4 <script src="../../http/tests/inspector/timeline-test.js"></script> |
| 5 <script> | 5 <script> |
| 6 | 6 |
| 7 function performActions() | 7 function performActions() |
| 8 { | 8 { |
| 9 var element = document.getElementById("animation"); | 9 var element = document.getElementById("animation"); |
| 10 var requestId = window.requestAnimationFrame(animationFrameCallback, element
); | 10 var requestId = window.requestAnimationFrame(animationFrameCallback, element
); |
| 11 function animationFrameCallback() | 11 function animationFrameCallback() |
| 12 { | 12 { |
| 13 window.cancelAnimationFrame(requestId); | 13 window.cancelAnimationFrame(requestId); |
| 14 } | 14 } |
| 15 | |
| 16 if (window.testRunner) | |
| 17 testRunner.display(); | |
| 18 } | 15 } |
| 19 | 16 |
| 20 function test() | 17 function test() |
| 21 { | 18 { |
| 22 WebInspector.TimelineModel._doNotAssignEndTime = true; | 19 WebInspector.TimelineModel._doNotAssignEndTime = true; |
| 23 InspectorTest.startTimeline(function() { | 20 InspectorTest.startTimeline(function() { |
| 24 InspectorTest.evaluateInPage("performActions()"); | 21 InspectorTest.evaluateInPage("performActions()"); |
| 25 }); | 22 }); |
| 26 | 23 |
| 27 InspectorTest.waitForRecordType("CancelAnimationFrame", finish); | 24 InspectorTest.waitForRecordType("CancelAnimationFrame", finish); |
| (...skipping 16 matching lines...) Expand all Loading... |
| 44 <body onload="runTest()"> | 41 <body onload="runTest()"> |
| 45 <p> | 42 <p> |
| 46 Tests the Timeline events for Animation Frame feature | 43 Tests the Timeline events for Animation Frame feature |
| 47 </p> | 44 </p> |
| 48 <div id="animation"> | 45 <div id="animation"> |
| 49 | 46 |
| 50 </div> | 47 </div> |
| 51 | 48 |
| 52 </body> | 49 </body> |
| 53 </html> | 50 </html> |
| OLD | NEW |