Opened 9 years ago
Closed 9 years ago
#13741 closed defect (fixed)
AccordionContainer: addChild broken by textNodes and comments
Reported by: | Karl Tiedt | Owned by: | bill |
---|---|---|---|
Priority: | high | Milestone: | 1.7 |
Component: | Dijit | Version: | 1.6.1 |
Keywords: | StackContainer AccordionContainer TabContainer addChild textNode commentNode | Cc: | |
Blocked By: | Blocking: |
Description
If AccordionContainer? is the child of a widgetsInTemplate widget and the template is not laid out perfectly... (arguable term since perfect is the horrendous looking format that requires opening and closing tags on separate lines to prevent spurious textNodes)
when addChild does insertBefore() it uses childNodes[] which includes textNodes and commentNodes (which arent valid children) and then inserts the new child before them instead of the valid children.
Change History (3)
comment:1 Changed 9 years ago by
comment:2 Changed 9 years ago by
Milestone: | tbd → 1.7 |
---|---|
Owner: | set to bill |
Status: | new → assigned |
Nevermind, I made one. As Karl said on IM, after the AccordionContainer is started, it doesn't call _Container.addChild() but rather executes custom code.
Note: See
TracTickets for help on using
tickets.
_Container.addChild() is supposed to handle this by calling getChildren() (which will ignore text nodes since they aren't widgets), and then used the returned children to execute a call like dojo.place(newNode, refNode, "after").
So, please attach a test case, thanks.