Chromium Code Reviews| Index: third_party/WebKit/LayoutTests/svg/css/cursor-change-href.svg |
| diff --git a/third_party/WebKit/LayoutTests/svg/css/cursor-change-href.svg b/third_party/WebKit/LayoutTests/svg/css/cursor-change-href.svg |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..c1692f193149ac8fc67d21b23fd67f578cc250ba |
| --- /dev/null |
| +++ b/third_party/WebKit/LayoutTests/svg/css/cursor-change-href.svg |
| @@ -0,0 +1,32 @@ |
| +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> |
| + <g style="cursor:url(#cursor), auto"> |
| + <g> |
| + <rect id="rect" x="50" y="50" width="100" height="100" fill="green" /> |
|
rune
2015/11/30 14:22:58
Indentation looks funny.
|
| + <text id="result1" x="50" y="200">Not run.</text> |
| + <text id="result2" x="50" y="220">Not run.</text> |
| + </g> |
| + </g> |
| + <cursor id="cursor" xlink:href="icon1.ico" x="0" y="0" /> |
| + <script> |
| + // Modifying href of a cursor element should cause a recalc of elements using it. |
| + |
| + if (window.testRunner) |
| + testRunner.dumpAsText(); |
| + |
| + var rect = document.getElementById("rect"); |
| + var result1 = document.getElementById("result1").firstChild; |
| + var result2 = document.getElementById("result2").firstChild; |
| + |
| + if (getComputedStyle(rect).cursor == "url(\"file:///home/rune/dev/src/third_party/WebKit/LayoutTests/svg/css/icon1.ico\"), auto") |
| + result1.data = "PASS"; |
| + else |
| + result1.data = "FAIL - " + getComputedStyle(rect).cursor; |
| + |
| + document.getElementById("cursor").setAttribute("xlink:href", "icon2.ico"); |
| + |
| + if (getComputedStyle(rect).cursor == "url(\"file:///home/rune/dev/src/third_party/WebKit/LayoutTests/svg/css/icon2.ico\"), auto") |
| + result2.data = "PASS"; |
| + else |
| + result2.data = "FAIL - " + getComputedStyle(rect).cursor; |
| + </script> |
| +</svg> |