OLD | NEW |
1 <?xml version="1.0" encoding="UTF-8" standalone="no"?> | 1 <?xml version="1.0" encoding="UTF-8" standalone="no"?> |
2 <svg xmlns="http://www.w3.org/2000/svg" | 2 <svg xmlns="http://www.w3.org/2000/svg" |
3 xmlns:xlink="http://www.w3.org/1999/xlink" | 3 xmlns:xlink="http://www.w3.org/1999/xlink" |
4 xmlns:xhtml="http://www.w3.org/1999/xhtml" onload="runTest()"> | 4 xmlns:xhtml="http://www.w3.org/1999/xhtml" onload="runTest()"> |
5 | 5 |
6 <!-- Test for http://crbug.com/165180 --> | 6 <!-- Test for http://crbug.com/165180 --> |
7 <defs> | 7 <defs> |
8 <filter id="f"> | 8 <filter id="f"> |
9 <feOffset/> | 9 <feOffset/> |
10 </filter> | 10 </filter> |
11 </defs> | 11 </defs> |
12 | 12 |
13 <rect id="r" width="100%" height="100%" fill="yellow"/> | 13 <rect id="r" width="100%" height="100%" fill="yellow"/> |
14 <g filter="url(#f)"> | 14 <g filter="url(#f)"> |
15 <foreignObject width="100%" height="100%"> | 15 <foreignObject width="100%" height="100%"> |
16 <xhtml:div id="div" style="width: 99px; height: 100px; background-color: r
ed;"></xhtml:div> | 16 <xhtml:div id="div" style="width: 99px; height: 100px; background-color: r
ed;"></xhtml:div> |
17 </foreignObject> | 17 </foreignObject> |
18 </g> | 18 </g> |
19 | 19 |
20 <script> | 20 <script> |
21 function runTest() { | 21 function runTest() { |
22 if (window.testRunner) { | 22 if (window.testRunner) { |
23 testRunner.waitUntilDone(); | 23 testRunner.waitUntilDone(); |
24 testRunner.display(); | |
25 } | 24 } |
26 | 25 |
27 setTimeout(function() { | 26 window.requestAnimationFrame(function() { |
28 document.getElementById('div').style.backgroundColor = 'green'; | 27 setTimeout(function() { |
29 document.getElementById('div').style.width = '100px'; | 28 document.getElementById('div').style.backgroundColor = 'green'; |
| 29 document.getElementById('div').style.width = '100px'; |
30 | 30 |
31 // Force a full redraw to get rid of the display() shade and make re
f-testing feasible. | 31 // Force a full redraw to get rid of the display() shade and mak
e ref-testing feasible. |
32 document.getElementById('r').setAttribute('fill', 'none'); | 32 document.getElementById('r').setAttribute('fill', 'none'); |
33 | 33 |
34 if (window.testRunner) | 34 if (window.testRunner) |
35 testRunner.notifyDone(); | 35 testRunner.notifyDone(); |
36 }, 0); | 36 }, 0); |
37 | 37 }); |
38 } | 38 } |
39 </script> | 39 </script> |
40 </svg> | 40 </svg> |
OLD | NEW |