|
|
Re: java combobox
|
Posted: Nov 8, 2004 7:34 AM
|
|
What do you mean by Key selection? The displayed text should be different from the return value?
You need 2 things for that:
1. a class wich containes the key and the display string (I created a class called ComboBoxString containing key, text and icon 2. a renderer for the ComboBox. It should extend the standard-renderer.When called, it should check if the item is a ComboBoxString, then create a panel with the icon and the text. If it's something else, it should simply call the render-method of the super class.
|
|