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..813276390e44884e335a853afd91f0d193e1ce36 |
| --- /dev/null |
| +++ b/third_party/WebKit/LayoutTests/svg/custom/object-current-scale.html |
| @@ -0,0 +1,25 @@ |
| +<!DOCTYPE html> |
| +<script src="../../resources/run-after-layout-and-paint.js"></script> |
| +<script> |
| + if (window.testRunner) |
| + testRunner.waitUntilDone(); |
| + |
| + function setScale() { |
| + var obj = document.querySelector("object"); |
| + var svgdoc = obj.contentDocument; |
| + var svgroot = svgdoc.documentElement; |
| + svgroot.currentScale = 0.5; |
| + runAfterLayoutAndPaint(function() { |
| + if (window.testRunner) |
|
fs
2016/03/31 10:53:04
You can pass 'true' as the second argument to runA
Shanmuga Pandi
2016/03/31 11:53:35
Done.
|
| + testRunner.notifyDone(); |
| + }); |
| + } |
| +</script> |
| + |
| +<body> |
|
fs
2016/03/31 10:53:04
You don't need this <body>.
Shanmuga Pandi
2016/03/31 11:53:35
Done.
|
| + <object onload="setScale()" data="resources/green-rect.svg" type="image/svg+xml"> |
| + </object> |
| + <svg width='400' height='400' viewBox='0 0 200 200'> |
|
fs
2016/03/31 10:53:04
This is a pretty roundabout way to get a 100x100 r
Shanmuga Pandi
2016/03/31 11:53:35
Acknowledged.
|
| + <rect width='50' height='50' fill='green'/> |
| + </svg> |
| +</body> |