Santhosh has been busy rearranging Swing components and models again. His latest creations are Editable JLists and TreeModels in JComboBoxes. Things like this make you wonder what is going to happen next Apple and Intel? ... Oh wait a second that happened also =). Anyway, I'm glad someone has time to cook up implementations of things I've thought about writing myself. I do have to wonder if Santhosh has a day job with all the code he cranks out. I used to wonder the same thing about Romain until I found out that he really didn't have a day job =).
Tree inside JComboBox I have a TreeModel and TreeCellRenderer, and I want to show a tree inside a JComboBox popup.
JComboBox requires ComboBoxModel, but we have TreeModel, Why don't try to create an adapter named TreeListModel which lets you view TreeModel as if it is a ListModel.
Making JList Editable (no JTable) If you search for "JList editable" in google, you will find many pages. But all of them use the following approach:
JTable with one column without JTableHeader = Editable JList
I hate this approach. I don't find any reasons why JList is not editable. What if Sun doesn't provide editable JList. I don't care.
Why can't I add editing support to JList in the same way how JTable adds editing support. Thus this Blog Entry took its birth....