| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <style type="text/css"> | 4 <style type="text/css"> |
| 5 .absolute { | 5 .absolute { |
| 6 background-color: green; | 6 background-color: green; |
| 7 height: 96px; | 7 height: 96px; |
| 8 position: absolute; | 8 position: absolute; |
| 9 top: 0; | 9 top: 0; |
| 10 left: 0; | 10 left: 0; |
| (...skipping 13 matching lines...) Expand all Loading... |
| 24 | 24 |
| 25 .transformed { | 25 .transformed { |
| 26 background-color: #6d6d6d; | 26 background-color: #6d6d6d; |
| 27 padding-top: 24px; | 27 padding-top: 24px; |
| 28 margin: 64px 0px 1920px 0px; | 28 margin: 64px 0px 1920px 0px; |
| 29 width: 100%; | 29 width: 100%; |
| 30 height: 40px; | 30 height: 40px; |
| 31 -webkit-transform: translateZ(0); | 31 -webkit-transform: translateZ(0); |
| 32 } | 32 } |
| 33 </style> | 33 </style> |
| 34 <script src="../../fast/repaint/resources/repaint.js"></script> | 34 <script src="../../resources/run-after-display.js"></script> |
| 35 <script type="text/javascript" charset="utf-8"> | 35 <script type="text/javascript" charset="utf-8"> |
| 36 if (window.testRunner) { | 36 if (window.testRunner) { |
| 37 testRunner.dumpAsTextWithPixelResults(); | 37 testRunner.dumpAsTextWithPixelResults(); |
| 38 testRunner.waitUntilDone(); | 38 testRunner.waitUntilDone(); |
| 39 } | 39 } |
| 40 | 40 |
| 41 function repaintTest() | |
| 42 { | |
| 43 window.scrollBy(0,-96); | |
| 44 if (window.testRunner) | |
| 45 testRunner.notifyDone(); | |
| 46 } | |
| 47 | |
| 48 function doTest() | 41 function doTest() |
| 49 { | 42 { |
| 50 window.scrollBy(0,-2048); | 43 window.scrollBy(0,-2048); |
| 51 window.scrollBy(0,160); | 44 window.scrollBy(0,160); |
| 52 runRepaintTest(); | 45 runAfterDisplay(function() { |
| 46 window.scrollBy(0,-96); |
| 47 if (window.testRunner) |
| 48 testRunner.notifyDone(); |
| 49 }); |
| 53 } | 50 } |
| 54 window.addEventListener('load', doTest, false); | 51 window.addEventListener('load', doTest, false); |
| 55 </script> | 52 </script> |
| 56 </head> | 53 </head> |
| 57 <body> | 54 <body> |
| 58 <div class="absolute"></div> | 55 <div class="absolute"></div> |
| 59 <div class="fixed"></div> | 56 <div class="fixed"></div> |
| 60 <div class="transformed"></div> | 57 <div class="transformed"></div> |
| 61 <p> For this test to pass, you should not see a red line when scroll positio
n is less or equal to 64px from the top. </p> | 58 <p> For this test to pass, you should not see a red line when scroll positio
n is less or equal to 64px from the top. </p> |
| 62 </body> | 59 </body> |
| 63 </html> | 60 </html> |
| OLD | NEW |