msterjev
asked on
JTree question
I have JTree which a fill with nodes at the first time.
After that a call removeAllChildren() method for some node and I am adding a brand new set of nodes as childrens for this node. Why the JTree doesn't changes? (There are only interrupted lines to previous childs which are still visible)!
After that a call removeAllChildren() method for some node and I am adding a brand new set of nodes as childrens for this node. Why the JTree doesn't changes? (There are only interrupted lines to previous childs which are still visible)!
ASKER
The events are minor problem. Give me example how to dinamically change structure of one node( remove all its childrens and add new ones)!
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
The tree node do not support firing TreeModelEvent's.
If you change your nodes you must also ensure that the matching events are fired by your tree model.