OLD | NEW |
(Empty) | |
| 1 <script> |
| 2 if (window.testRunner) |
| 3 testRunner.waitUntilDone(); |
| 4 onload = function() { |
| 5 // Double rAF to ensure content is painted before scroll. |
| 6 requestAnimationFrame(function() { |
| 7 requestAnimationFrame(function() { |
| 8 document.getElementById('scroller').scrollTo(0, 200); |
| 9 if (window.testRunner) |
| 10 window.testRunner.notifyDone(); |
| 11 }) |
| 12 }); |
| 13 } |
| 14 </script> |
| 15 <style> |
| 16 #scroller { |
| 17 background: gray local content-box; |
| 18 border: 10px solid rgba(0, 255, 0, 0.5); |
| 19 overflow: scroll; |
| 20 padding: 10px; |
| 21 width: 200px; |
| 22 height: 200px; |
| 23 will-change: transform; |
| 24 } |
| 25 |
| 26 .spacer { |
| 27 height: 300px; |
| 28 } |
| 29 </style> |
| 30 <div id="scroller"> |
| 31 <div class="spacer"></div> |
| 32 </div> |
OLD | NEW |