This post originated from an RSS feed registered with Java Buzz
by Scott Delap.
Original Post: JComboBox and Separators
Feed Title: ClientJava.com
Feed URL: http://www.clientjava.com/archives/wireless_mobile.rdf
Feed Description: Client/Desktop Related Java Development
JComboBox and separators Thunderbird has a super-useful dropdown above the message pane for quick filtering. I wanted to implement something like that in Java for JDeveloper.
There are three particular aspects of this drop down that I wanted to emulate using the Swing JComboBox control:
* It contains predefined filters separated into logical groups.
* It has a Customize... item at the end. When you select this, it invokes a dialog.
* If you navigate through the items with the keyboard while the dropdown is visible, the filters are not immediately applied. This only happens when you hit enter