Set Size of JComboBox PopupMenu
i am programming a custom component which extends a JComboBox. My problem is, the PopupMenu won't actualise its size if i am adding or removing an item. So there are e.g. 2 items in the list, but if there were 4 before i had 2 "empty" items in the PopupMenu as well. The only workaround i found was to do (in JIntelligentComboBox.java line 213) this.setPopupVisible(false); this.setPopupVisible(true); but the result will be a flickering PopupMenu :-( So what else could i do to refresh/repaint the PopupMenu without flickering? For testing: the component and a little test programm To generate my