OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <style> | 2 <style> |
3 .green { | 3 .green { |
4 background-color: green; | 4 background-color: green; |
5 } | 5 } |
6 .box { | 6 .box { |
7 width: 200px; | 7 width: 200px; |
8 height: 200px; | 8 height: 200px; |
9 position: absolute; | 9 position: absolute; |
10 left: 300px; | 10 left: 300px; |
11 } | 11 } |
12 .reflected { | 12 .reflected { |
13 -webkit-box-reflect: right 50px; | 13 -webkit-box-reflect: right 50px; |
14 } | 14 } |
15 </style> | 15 </style> |
16 <!-- | 16 <!-- |
17 This test checks that we correctly invalidate reflection when they are remov
ed. | 17 This test checks that we correctly invalidate reflection when they are remov
ed. |
18 There should be only one green box below. | 18 There should be only one green box below. |
19 --> | 19 --> |
20 <div class="green reflected box" id="box"></div> | 20 <div class="green reflected box" id="box"></div> |
21 <script src="resources/text-based-repaint.js"></script> | 21 <script src="resources/text-based-repaint.js"></script> |
22 <script> | 22 <script> |
23 function repaintTest() { | 23 function repaintTest() { |
24 var box = document.getElementById('box'); | 24 var box = document.getElementById('box'); |
25 box.classList.toggle('reflected'); | 25 box.classList.toggle('reflected'); |
26 } | 26 } |
27 window.onload = runRepaintTest; | 27 window.onload = runRepaintAndPixelTest; |
28 </script> | 28 </script> |
OLD | NEW |