Wednesday, December 19, 2001 01:03 PM
I have a custom TreeModel representing the nodes of a JTree. It works fine; if certain attributes of the nodes change, and those changes warrant a change in the GUI, I am able to make those changes appear.
However, if I change the structure of the model -- by removing a node, for example -- then the model is correctly changed, but the JTree does not reflect those changes.
I know that I need to fire an event of some sort, but none of the JTree fire* methods seem appropriate. (I need something like JTree.nodesRemoved().)
I'm uncertain how to communicate those changes to the tree. (It seems to me that it should be done automatically, but that's just how I'd do it.)
Re: Custom TreeModel
Wednesday, December 19, 2001 01:17 PM