Opened 7 years ago

Closed 7 years ago

#14617 closed defect (invalid)

Tree view programmatic collapse not working

Reported by: ta12121 Owned by:
Priority: high Milestone: tbd
Component: Dijit Version: 1.6.1
Keywords: tree view collapse node Cc:
Blocked By: Blocking:

Description

Programmatically collapsing a tree view node leaves the node unexpandable by mouse clicks from the user. Please see an example here: <http://pastebin.com/F3TF7F4w>.

Change History (2)

comment:1 Changed 7 years ago by ta12121

I tested with 1.7.1 and the bug occurs in that version too.

comment:2 Changed 7 years ago by bill

Resolution: invalid
Status: newclosed

Thanks for the test case.

Although there's no official way to close/open a single tree node programatically, there is a way to do it:

tree_view._collapseNode(tree_view.rootNode.getChildren()[0]);

What you are doing won't work, and isn't supposed to:

tree_view.rootNode.getChildren()[0].collapse();

Note also that you can do tree_view.set("path", ...) to open the tree to a certain node, and select it.

Note: See TracTickets for help on using tickets.