OLD | NEW |
---|---|
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <script src="../../resources/run-after-layout-and-paint.js"></script> | 2 <script src="../../resources/run-after-layout-and-paint.js"></script> |
3 <script src="resources/text-based-repaint.js"></script> | 3 <script src="resources/text-based-repaint.js"></script> |
4 <script> | 4 <script> |
5 function repaintTest() { | 5 function repaintTest() { |
6 content.style.height = '100px'; | 6 content.style.height = '100px'; |
7 content.style.backgroundColor = 'green'; | 7 content.style.backgroundColor = 'green'; |
8 } | 8 } |
9 onload = function() { | 9 onload = function() { |
10 runAfterLayoutAndPaint(function() { | 10 runAfterLayoutAndPaint(function() { |
11 container.style.height = '400px'; | 11 container.style.height = '400px'; |
12 runRepaintAndPixelTest(); | 12 runRepaintAndPixelTest(); |
13 }); | 13 }); |
14 }; | 14 }; |
15 </script> | 15 </script> |
16 Tests paint invalidation of previous location of an element which was clipped to be invisible initially, becme visible because of clip change, then changed colo r and size. Passes if there is a green square. | 16 Tests paint invalidation of previous location of an element which was clipped to be invisible initially, becme visible because of clip change, then changed colo r and size. Passes if there is a green square. |
17 <div id="container" style="position: absolute; top: 100px; width: 100px; height: 10px; overflow: hidden"> | 17 <div id="container" style="position: absolute; top: 100px; width: 100px; height: 10px; overflow: hidden"> |
18 <div style="height: 20px"></div> | 18 <div style="height: 20px"></div> |
19 <div style="width: 100px; height: 300px"> | 19 <!-- These two levels of divs are to isolate layout when container resizes. -- > |
20 <div id="content" style="width: 100px; height: 300px; background-color: red" ></div> | 20 <div style="width: 100px; height: 300px; overflow: hidden"> |
chrishtr
2017/02/28 22:45:28
Add a new test rather than modifying the existing
Xianzhu
2017/03/01 00:03:33
The original test has been unable to test its orig
chrishtr
2017/03/01 00:51:58
Ok.
| |
21 <div style="width: 100px; height: 300px; overflow: hidden"> | |
22 <div id="content" style="width: 100px; height: 300px; background-color: re d"></div> | |
23 </div> | |
21 </div> | 24 </div> |
22 </div> | 25 </div> |
OLD | NEW |