bibliothek.gui.dock.themes.basic.action.dropdown
Class SelectableDropDownHandler
java.lang.Object
bibliothek.gui.dock.themes.basic.action.menu.AbstractMenuHandler<JMenuItem,S>
bibliothek.gui.dock.themes.basic.action.dropdown.AbstractDropDownHandler<SelectableDockAction>
bibliothek.gui.dock.themes.basic.action.dropdown.SelectableDropDownHandler
- All Implemented Interfaces:
- ViewItem<JComponent>, DropDownViewItem, MenuViewItem<JComponent>
- Direct Known Subclasses:
- SelectableDropDownHandler.Check, SelectableDropDownHandler.Radio
public abstract class SelectableDropDownHandler
- extends AbstractDropDownHandler<SelectableDockAction>
A connection between a SelectableDockAction
and a
drop-down-button.
- Author:
- Benjamin Sigg
Method Summary |
void |
bind()
Connects this handler to its action. |
protected abstract void |
itemTriggered()
Called if the menuitem was clicked. |
void |
setView(DropDownView view)
Sends the current settings of this item to the view. |
void |
unbind()
Disconnects this handler from its action |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SelectableDropDownHandler
public SelectableDropDownHandler(SelectableDockAction action,
Dockable dockable,
JMenuItem item)
- Creates a new handler.
- Parameters:
action
- the action to observedockable
- the Dockable for which the action is shownitem
- the graphical representation of the action
bind
public void bind()
- Description copied from class:
AbstractMenuHandler
- Connects this handler to its action.
- Specified by:
bind
in interface ViewItem<JComponent>
- Overrides:
bind
in class AbstractDropDownHandler<SelectableDockAction>
unbind
public void unbind()
- Description copied from class:
AbstractMenuHandler
- Disconnects this handler from its action
- Specified by:
unbind
in interface ViewItem<JComponent>
- Overrides:
unbind
in class AbstractDropDownHandler<SelectableDockAction>
setView
public void setView(DropDownView view)
- Description copied from interface:
DropDownViewItem
- Sends the current settings of this item to the view. The values
can be changed as long as the view is registered.
- Specified by:
setView
in interface DropDownViewItem
- Overrides:
setView
in class AbstractDropDownHandler<SelectableDockAction>
- Parameters:
view
- the view, might be null
itemTriggered
protected abstract void itemTriggered()
- Called if the menuitem was clicked.