Export to GitHub

svgweb - issue #296

appendChild of existing child should move it to the end


Posted on Sep 16, 2009 by Grumpy Dog

What steps will reproduce the problem? 1. node.parent.appendChild(node)

What is the expected output? What do you see instead? This should move the child to the end of the child list. Instead it appears to add another copy of the child.

Comment #1

Posted on Sep 16, 2009 by Massive Bird

(No comment was entered for this change.)

Comment #2

Posted on Sep 29, 2009 by Grumpy Dog

Additional details available in Issue 328.

Comment #3

Posted on Sep 29, 2009 by Grumpy Dog

Issue 328 has been merged into this issue.

Comment #4

Posted on Sep 30, 2009 by Helpful Panda

This defect is blocking the following Dojo GFX test cases:

FAIL test_group1.html: partly works, but rect highlight change has problem FAIL test_tbbox.html: output drawing is incorrect FAIL test_transform.html: output drawing is incorrect

See http://bugs.dojotoolkit.org/ticket/9948

Comment #5

Posted on Oct 20, 2009 by Massive Bird

(No comment was entered for this change.)

Comment #6

Posted on Dec 22, 2009 by Helpful Panda

I attempted a fix, seems to work well, at least for issue 328. Appreciate your review and comments.

Attachments

Comment #7

Posted on Dec 22, 2009 by Massive Bird

(No comment was entered for this change.)

Comment #8

Posted on Dec 22, 2009 by Massive Bird

Thanks for the patch; I'll take a look at this soon. It might be a bit delayed with the U.S. holidays here.

Comment #9

Posted on Mar 28, 2010 by Grumpy Dog

Fixed in r1050. Issue 296: Remove child if already present for methods that add a child. Thanks to young4chong for the patch.

Status: Fixed

Labels:
Type-Defect Priority-High Patch