| <!DOCTYPE html> |
| <html> |
| <head> |
| <style type='text/css'> |
| body { |
| height: 1000px; |
| } |
| |
| .green { |
| background-color: green; |
| } |
| |
| .fixed { |
| position: fixed; |
| top: 0px; |
| left: 0px; |
| } |
| |
| .box { |
| width: 300px; |
| height: 300px; |
| } |
| |
| .container { |
| position: relative; |
| } |
| |
| .perspective { |
| -webkit-perspective: 1px; |
| } |
| </style> |
| <script> |
| if (window.testRunner) { |
| testRunner.dumpAsText(true); |
| } |
| |
| function doTest() |
| { |
| if (window.testRunner) |
| testRunner.displayAndTrackRepaints(); |
| |
| // Any scroll should keep the fixed-position element where it is. |
| // If it stutters or disappears incorrectly, then the red background will be revealed. |
| window.scrollTo(0, 150); |
| } |
| |
| window.addEventListener('load', doTest, false); |
| </script> |
| </head> |
| <body> |
| <div class="green fixed box"> |
| <div class="container"> |
| <div class="perspective"></div> |
| </div> |
| </div> |
| </body> |
| </html> |