| OLD | NEW |
| 1 <html> | 1 <html> |
| 2 <head> | 2 <head> |
| 3 <script type="text/javascript" src="../../http/tests/inspector-protocol/inspecto
r-protocol-test.js"></script> | 3 <script type="text/javascript" src="../../http/tests/inspector-protocol/inspecto
r-protocol-test.js"></script> |
| 4 <script type="text/javascript" src="../../http/tests/inspector-protocol/tracing-
test.js"></script> | 4 <script type="text/javascript" src="../../http/tests/inspector-protocol/tracing-
test.js"></script> |
| 5 <script> | 5 <script> |
| 6 | 6 |
| 7 function performActions(callback) | 7 function performActions(callback) |
| 8 { | 8 { |
| 9 var rafId1 = requestAnimationFrame(function() | 9 var rafId1 = requestAnimationFrame(function() |
| 10 { | 10 { |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 InspectorTest.log("SUCCESS: testFunctionRequestAnimationFrame"); | 29 InspectorTest.log("SUCCESS: testFunctionRequestAnimationFrame"); |
| 30 } | 30 } |
| 31 | 31 |
| 32 function finish(devtoolsEvents) | 32 function finish(devtoolsEvents) |
| 33 { | 33 { |
| 34 function hasRafId(id, e) { return e.args.data.id === id} | 34 function hasRafId(id, e) { return e.args.data.id === id} |
| 35 | 35 |
| 36 var raf1 = InspectorTest.findEvent("RequestAnimationFrame", "I", hasRafI
d.bind(this, firedRaf)); | 36 var raf1 = InspectorTest.findEvent("RequestAnimationFrame", "I", hasRafI
d.bind(this, firedRaf)); |
| 37 var raf2 = InspectorTest.findEvent("RequestAnimationFrame", "I", hasRafI
d.bind(this, canceledRaf)); | 37 var raf2 = InspectorTest.findEvent("RequestAnimationFrame", "I", hasRafI
d.bind(this, canceledRaf)); |
| 38 | 38 |
| 39 InspectorTest.assert(!!raf1.args.data.frame, "RequestAnimationFrame fram
e"); | 39 InspectorTest.log("RequestAnimationFrame has frame: " + !!raf1.args.data
.frame); |
| 40 InspectorTest.assertEquals(raf1.args.data.frame, raf2.args.data.frame, "
RequestAnimationFrame frame match"); | 40 InspectorTest.log("RequestAnimationFrame frames match: " + (raf1.args.da
ta.frame === raf2.args.data.frame)); |
| 41 | 41 |
| 42 InspectorTest.findEvent("CancelAnimationFrame", "I", hasRafId.bind(this,
canceledRaf)); | 42 InspectorTest.findEvent("CancelAnimationFrame", "I", hasRafId.bind(this,
canceledRaf)); |
| 43 InspectorTest.findEvent("FireAnimationFrame", "X", hasRafId.bind(this, f
iredRaf)); | 43 InspectorTest.findEvent("FireAnimationFrame", "X", hasRafId.bind(this, f
iredRaf)); |
| 44 | 44 |
| 45 InspectorTest.log("SUCCESS: found all expected events."); | 45 InspectorTest.log("SUCCESS: found all expected events."); |
| 46 InspectorTest.completeTest(); | 46 InspectorTest.completeTest(); |
| 47 } | 47 } |
| 48 } | 48 } |
| 49 </script> | 49 </script> |
| 50 </head> | 50 </head> |
| 51 <body onLoad="runTest();"> | 51 <body onLoad="runTest();"> |
| 52 <div id="myDiv">DIV</div> | 52 <div id="myDiv">DIV</div> |
| 53 </body> | 53 </body> |
| 54 </html> | 54 </html> |
| OLD | NEW |