Editable JLabel

Hy all,

I want to make a JLabel that is in a JList editable.

I have been thinking on how to do that. I am posting this thread so i can share my idea and perhaps get some feedback or other ideas that might work.

My idea is the following

when i select the JLabel in the list and press a button labeled "Edit label" the label gets replaced by a JTextField and when i press enter or select another cell it will save the text to the label and replace the Textfield with the label again.

Do u guyz think this is the way to go? or is there another easyer way to do this.

[600 byte] By [S1lv3ra] at [2007-11-26 22:41:21]
# 1
You could just use a single-column JTable instead of a JList, which would support editing with no effort.
itchyscratchya at 2007-7-10 11:56:12 > top of Java-index,Desktop,Core GUI APIs...