Chromium Code Reviews| Index: third_party/WebKit/LayoutTests/svg/custom/object-current-scale.html |
| diff --git a/third_party/WebKit/LayoutTests/svg/custom/object-current-scale.html b/third_party/WebKit/LayoutTests/svg/custom/object-current-scale.html |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..23b1049ce381ddabd01028b53d78ec64965eb6d5 |
| --- /dev/null |
| +++ b/third_party/WebKit/LayoutTests/svg/custom/object-current-scale.html |
| @@ -0,0 +1,18 @@ |
| +<!DOCTYPE html> |
| +<script> |
| + if (window.testRunner) |
| + testRunner.waitUntilDone(); |
| + |
| + function setScale() { |
| + var obj = document.getElementById("object"); |
|
fs
2016/03/29 11:58:51
Could use querySelector and avoid the id=...
Shanmuga Pandi
2016/03/31 09:04:37
Done.
|
| + var svgdoc = obj.contentDocument; |
| + var svgroot = svgdoc.documentElement; |
| + svgroot.currentScale = 0.5; |
| + if (window.testRunner) |
| + setTimeout(function() { testRunner.notifyDone(); }, 0); |
|
fs
2016/03/29 11:58:51
Could you use runAfterLayoutAndPaint here instead?
Shanmuga Pandi
2016/03/31 09:04:37
Done.
|
| + } |
| +</script> |
| + |
| +<body> |
| + <object id="object" onload="setScale()" data="resources/green-rect.svg" type="image/svg+xml"/> |
|
fs
2016/03/29 11:58:51
I'd suggest that you add a "reference" (another gr
Shanmuga Pandi
2016/03/31 09:04:37
Done.
|
| +</body> |