Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(203)

Unified Diff: LayoutTests/svg/custom/image-reinsert.html

Issue 191933003: [SVG] Missing image loader update on re-insert. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: LayoutTests/svg/custom/image-reinsert.html
diff --git a/LayoutTests/svg/custom/image-reinsert.html b/LayoutTests/svg/custom/image-reinsert.html
new file mode 100644
index 0000000000000000000000000000000000000000..84ee076a531f941848d315049ca4cc930e87d046
--- /dev/null
+++ b/LayoutTests/svg/custom/image-reinsert.html
@@ -0,0 +1,24 @@
+<!DOCTYPE html>
+<html>
+<body>
+ <svg id="svg" width="200" height="200" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
+ <rect width="100" height="100" fill="red"/>
+ </svg>
+
+ <script>
+ var img = document.createElementNS('http://www.w3.org/2000/svg', 'image');
+ img.setAttribute('width', '100');
+ img.setAttribute('height', '100');
+ img.setAttributeNS('http://www.w3.org/1999/xlink', 'href', 'data:image/svg+xml,' +
+ '<svg xmlns="http://www.w3.org/2000/svg">' +
+ ' <rect width="100" height="100" fill="green"/>' +
+ '</svg>');
+
+ var inactive_doc = document.implementation.createDocument ('http://www.w3.org/1999/xhtml', 'html', null);
+ // First, insert into an inactive doc.
+ inactive_doc.documentElement.appendChild(img);
+ // Then re-insert into the current doc.
+ document.getElementById('svg').appendChild(img);
+ </script>
+</body>
+</html>
« no previous file with comments | « no previous file | LayoutTests/svg/custom/image-reinsert-expected.html » ('j') | Source/core/svg/SVGImageElement.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698