| OLD | NEW |
| 1 <!-- | 1 <!-- |
| 2 Calculating collapsed borders for big tables is expensive, so we cache them and
recalculate when needed. | 2 Calculating collapsed borders for big tables is expensive, so we cache them and
recalculate when needed. |
| 3 Here we change cell border width, expect that cache is invalidated and paint pro
duces expected image. | 3 Here we change cell border width, expect that cache is invalidated and paint pro
duces expected image. |
| 4 --> | 4 --> |
| 5 <html> | 5 <html> |
| 6 <head> | 6 <head> |
| 7 <title></title> | 7 <title></title> |
| 8 <link rel="stylesheet" href="resources/cached.css"> | 8 <link rel="stylesheet" href="resources/cached.css"> |
| 9 <script src="../../../resources/run-after-display.js"></script> |
| 9 <script type="text/javascript"> | 10 <script type="text/javascript"> |
| 10 function test() { | 11 function test() { |
| 11 document.body.offsetTop; | |
| 12 if (window.testRunner) | 12 if (window.testRunner) |
| 13 testRunner.display(); | 13 testRunner.waitUntilDone(); |
| 14 document.getElementById("foo").style.borderWidth = "4px"; | 14 runAfterDisplay(function() { |
| 15 document.getElementById("foo").style.borderWidth = "4px"; |
| 16 document.getElementById("foo").style.borderColor = "lime"; |
| 17 if (window.testRunner) |
| 18 testRunner.notifyDone(); |
| 19 }); |
| 15 } | 20 } |
| 16 </script> | 21 </script> |
| 17 </head> | 22 </head> |
| 18 <body onload="test()"> | 23 <body onload="test()"> |
| 19 <table style="border-collapse:collapse; border:2px solid blue"> | 24 <table style="border-collapse:collapse; border:2px solid blue"> |
| 20 <tr> | 25 <tr> |
| 21 <td style="border:1px solid lime" id="foo"/> | 26 <td style="border:1px solid lime" id="foo"/> |
| 22 <td style="border:1px solid black"/> | 27 <td style="border:1px solid black"/> |
| 23 </tr> | 28 </tr> |
| 24 </table> | 29 </table> |
| 25 </body> | 30 </body> |
| 26 </html> | 31 </html> |
| 27 | 32 |
| OLD | NEW |