| OLD | NEW |
| 1 <!DOCTYPE HTML> | 1 <!DOCTYPE HTML> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <script src="../../../http/tests/inspector/inspector-test.js"></script> | 4 <script src="../../../http/tests/inspector/inspector-test.js"></script> |
| 5 <script src="../../../http/tests/inspector/timeline-test.js"></script> | 5 <script src="../../../http/tests/inspector/timeline-test.js"></script> |
| 6 <script> | 6 <script> |
| 7 function display() | 7 function display() |
| 8 { | 8 { |
| 9 document.getElementById("testElement").style.width = "100px"; | 9 document.getElementById("testElement").style.width = "100px"; |
| 10 var forceLayout1 = document.body.offsetTop; | 10 var forceLayout1 = document.body.offsetTop; |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 } | 23 } |
| 24 | 24 |
| 25 function test() | 25 function test() |
| 26 { | 26 { |
| 27 Runtime.experiments.enableForTest("timelineInvalidationTracking"); | 27 Runtime.experiments.enableForTest("timelineInvalidationTracking"); |
| 28 | 28 |
| 29 InspectorTest.runTestSuite([ | 29 InspectorTest.runTestSuite([ |
| 30 function testLocalFrame(next) | 30 function testLocalFrame(next) |
| 31 { | 31 { |
| 32 InspectorTest.invokeAsyncWithTimeline("display", function() { | 32 InspectorTest.invokeAsyncWithTimeline("display", function() { |
| 33 InspectorTest.dumpInvalidations(WebInspector.TimelineModel.Recor
dType.Layout, 0, "first layout invalidations"); | 33 InspectorTest.dumpInvalidations(TimelineModel.TimelineModel.Reco
rdType.Layout, 0, "first layout invalidations"); |
| 34 InspectorTest.dumpInvalidations(WebInspector.TimelineModel.Recor
dType.Layout, 1, "second layout invalidations"); | 34 InspectorTest.dumpInvalidations(TimelineModel.TimelineModel.Reco
rdType.Layout, 1, "second layout invalidations"); |
| 35 next(); | 35 next(); |
| 36 }); | 36 }); |
| 37 }, | 37 }, |
| 38 | 38 |
| 39 function testSubframe(next) | 39 function testSubframe(next) |
| 40 { | 40 { |
| 41 InspectorTest.invokeAsyncWithTimeline("updateSubframeAndDisplay", fu
nction() { | 41 InspectorTest.invokeAsyncWithTimeline("updateSubframeAndDisplay", fu
nction() { |
| 42 InspectorTest.dumpInvalidations(WebInspector.TimelineModel.Recor
dType.Layout, 0, "first layout invalidations"); | 42 InspectorTest.dumpInvalidations(TimelineModel.TimelineModel.Reco
rdType.Layout, 0, "first layout invalidations"); |
| 43 InspectorTest.dumpInvalidations(WebInspector.TimelineModel.Recor
dType.Layout, 1, "second layout invalidations"); | 43 InspectorTest.dumpInvalidations(TimelineModel.TimelineModel.Reco
rdType.Layout, 1, "second layout invalidations"); |
| 44 next(); | 44 next(); |
| 45 }); | 45 }); |
| 46 } | 46 } |
| 47 ]); | 47 ]); |
| 48 } | 48 } |
| 49 </script> | 49 </script> |
| 50 </head> | 50 </head> |
| 51 <body onload="runTest()"> | 51 <body onload="runTest()"> |
| 52 <p>Tests the Timeline API instrumentation of layout events with invalidations.</
p> | 52 <p>Tests the Timeline API instrumentation of layout events with invalidations.</
p> |
| 53 <div id="outerTestElement" style="display: inline-block;"><div id="testElement">
PASS</div></div> | 53 <div id="outerTestElement" style="display: inline-block;"><div id="testElement">
PASS</div></div> |
| 54 <iframe src="../resources/timeline-iframe-paint.html" style="position: absolute;
left: 40px; top: 40px; width: 100px; height: 100px; border: none"></iframe> | 54 <iframe src="../resources/timeline-iframe-paint.html" style="position: absolute;
left: 40px; top: 40px; width: 100px; height: 100px; border: none"></iframe> |
| 55 </body> | 55 </body> |
| 56 </html> | 56 </html> |
| OLD | NEW |