OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <script src="../../fast/repaint/resources/text-based-repaint.js"></script> | 2 <script src="resources/text-based-repaint.js"></script> |
3 <script src="../../editing/editing.js"></script> | 3 <script src="../../editing/editing.js"></script> |
4 <input id="root" style="will-change: transform" size="5" value="test test test"
> | 4 <input id="root" style="will-change: transform" size="5" value="test test test"
> |
5 <script> | 5 <script> |
6 window.testIsAsync = true; | 6 window.testIsAsync = true; |
7 onload = runRepaintTest; | 7 onload = runRepaintTest; |
8 if (window.internals) | 8 if (window.internals) |
9 window.internals.settings.setPreferCompositingToLCDTextEnabled(true); | 9 window.internals.settings.setPreferCompositingToLCDTextEnabled(true); |
10 | 10 |
11 function repaintTest() { | 11 function repaintTest() { |
12 root.focus(); | 12 root.focus(); |
13 root.scrollLeft = 200; | 13 root.scrollLeft = 200; |
14 requestAnimationFrame(function() { | 14 requestAnimationFrame(function() { |
15 execMoveSelectionForwardByWordCommand(); | 15 execMoveSelectionForwardByWordCommand(); |
16 execMoveSelectionForwardByWordCommand(); | 16 execMoveSelectionForwardByWordCommand(); |
17 execMoveSelectionForwardByWordCommand(); | 17 execMoveSelectionForwardByWordCommand(); |
18 finishRepaintTest(); | 18 finishRepaintTest(); |
19 }); | 19 }); |
20 } | 20 } |
21 </script> | 21 </script> |
OLD | NEW |