| OLD | NEW |
| 1 <!-- Based on fast/repaint/scroll-fixed-layer-with-no-visible-content.html --> |
| 1 <html> | 2 <html> |
| 2 <head> | 3 <head> |
| 3 <title></title> | 4 <title></title> |
| 4 <link rel="stylesheet" href="resources/default.css"></style> | 5 <link rel="stylesheet" href="../../../fast/repaint/resources/default.css"></
style> |
| 5 <script src="resources/text-based-repaint.js" type="text/javascript"></scrip
t> | 6 <script src="resources/paint-invalidation-test.js" type="text/javascript"></
script> |
| 6 <script type="text/javascript"> | 7 <script type="text/javascript"> |
| 7 if (window.testRunner) | |
| 8 testRunner.dumpAsTextWithPixelResults(); | |
| 9 | |
| 10 window.onload = function() { | 8 window.onload = function() { |
| 11 window.scrollTo(1000, 1000); | 9 window.scrollTo(1000, 1000); |
| 12 runRepaintTest(); | 10 runPaintInvalidationTest(); |
| 13 }; | 11 }; |
| 14 | 12 |
| 15 function repaintTest() | 13 window.expectedPaintInvalidationObjects = [ |
| 14 "LayoutBlockFlow (positioned) DIV id='moveMe' class='fixed clipped'"
, |
| 15 "LayoutBlockFlow (positioned) DIV class='absolute green'", |
| 16 ]; |
| 17 function paintInvalidationTest() |
| 16 { | 18 { |
| 17 var moveMeElement = document.getElementById('moveMe'); | 19 var moveMeElement = document.getElementById('moveMe'); |
| 18 moveMeElement.style.visibility = "visible"; | 20 moveMeElement.style.visibility = "visible"; |
| 19 moveMeElement.scrollTop = 100; | 21 moveMeElement.scrollTop = 100; |
| 20 moveMeElement.scrollLeft = 150; | 22 moveMeElement.scrollLeft = 150; |
| 21 } | 23 } |
| 22 </script> | 24 </script> |
| 23 </head> | 25 </head> |
| 24 <body style="height:2000px;"> | 26 <body style="height:2000px;"> |
| 25 <!-- You should see 1 green rectangle in the output and no red. --> | 27 <!-- You should see 1 green rectangle in the output and no red. --> |
| 26 <div id="moveMe" style="top: 150px; left: 100px; visibility: hidden" class="
fixed clipped"><div class="absolute green" style="top: 100px; left: 150px;"></di
v></div> | 28 <div id="moveMe" style="top: 150px; left: 100px; visibility: hidden" class="
fixed clipped"><div class="absolute green" style="top: 100px; left: 150px;"></di
v></div> |
| 27 <!-- Make sure we are scrolled --> | 29 <!-- Make sure we are scrolled --> |
| 28 <div style="top: 0px; left: 0px;" class="absolute red"></div> | 30 <div style="top: 0px; left: 0px;" class="absolute red"></div> |
| 29 </body> | 31 </body> |
| 30 </html> | 32 </html> |
| OLD | NEW |