public class JXComboBox.DelegatingRenderer extends Object implements ListCellRenderer, RolloverRenderer, UIDependent
| Constructor and Description |
|---|
DelegatingRenderer()
Instantiates a DelegatingRenderer with combo box's default renderer as delegate.
|
DelegatingRenderer(ListCellRenderer delegate)
Instantiates a DelegatingRenderer with the given delegate.
|
| Modifier and Type | Method and Description |
|---|---|
void |
doClick()
Same as AbstractButton.doClick().
|
ListCellRenderer |
getDelegateRenderer()
Returns the delegate.
|
Component |
getListCellRendererComponent(JList list,
Object value,
int index,
boolean isSelected,
boolean cellHasFocus) |
boolean |
isEnabled() |
void |
setDelegateRenderer(ListCellRenderer delegate)
Sets the delegate.
|
void |
updateUI()
Updates all internal visuals after changing a UI-delegate.
|
public DelegatingRenderer()
public DelegatingRenderer(ListCellRenderer delegate)
null, the default is created via the combo box's factory method.delegate - the delegate to use, if null the combo box's default is
created and used.public void setDelegateRenderer(ListCellRenderer delegate)
null, the default is created via the combo
box's factory method.delegate - the delegate to use, if null the list's default is created and used.public ListCellRenderer getDelegateRenderer()
public void updateUI()
updateUI in interface UIDependentJComponent.updateUI()public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected, boolean cellHasFocus)
Overridden to apply the highlighters, if any, after calling the delegate. The decorators are not applied if the row is invalid.
getListCellRendererComponent in interface ListCellRendererpublic boolean isEnabled()
isEnabled in interface RolloverRendererpublic void doClick()
doClick in interface RolloverRendererCopyright © 2017. All Rights Reserved.