I'm displaying a tree of custom objects, and I've got custom custom CellTreeEditor
and CellTreeRenderer
set.
Now what I really want is to always display all objects as in "edit mode". Right now I have the CellTreeRenderer.getTreeCellRendererComponent()
and CellTreeEditor.getTreeCellEditorComponent()
implemented almost identically. This kind of works, but I still have to click a node to focus it before I can do any editing.
Is there any more sensible way of doing this, perhaps like saying no renderer should never be used, defaulting to my CellTreeEditor
?
******UPDATE****
To clearify: What I have is a tree looking like this (and yes, it also looks like crap, but that's beside the point):
Right now, I accomplish this by having a renderer and an editor that returns identical components from getTreeCell[Renderer|Editor]Component()
.
If I click on the down-arrow on the ComboBox supplied by the renderer, it will flicker slighty as it opens the dropdown, but then be interrupted and replaced by my editor component. This means I have to click it again to open the dropdown. This is the behaviour I want to avoid.