|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object bibliothek.gui.dock.themes.basic.action.menu.AbstractMenuHandler<JMenuItem,S> bibliothek.gui.dock.themes.basic.action.dropdown.AbstractDropDownHandler<S>
S
- the type of action handled by this handlerpublic abstract class AbstractDropDownHandler<S extends StandardDropDownItemAction>
A handler that connects a StandardDropDownItemAction
with a
drop-down-button.
Field Summary |
---|
Fields inherited from class bibliothek.gui.dock.themes.basic.action.menu.AbstractMenuHandler |
---|
action, dockable, item |
Constructor Summary | |
---|---|
AbstractDropDownHandler(S action,
Dockable dockable,
JMenuItem item)
Creates an new handler. |
Method Summary | |
---|---|
void |
addActionListener(ActionListener listener)
Adds a listener which will be called if this view is triggered. |
void |
bind()
Connects this handler to its action. |
DropDownView |
getView()
Gets the view that can be used to send properties directly to the drop-down-button. |
boolean |
isSelectable()
Tells whether this item can be selected by the button. |
boolean |
isTriggerable(boolean selected)
Tells whether the item can be triggered if it is on the button or in the menu. |
void |
removeActionListener(ActionListener listener)
Removes a listener from this view. |
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 bibliothek.gui.dock.themes.basic.action.menu.AbstractMenuHandler |
---|
getAction, getDockable, getItem |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface bibliothek.gui.dock.themes.basic.action.dropdown.DropDownViewItem |
---|
triggered |
Methods inherited from interface bibliothek.gui.dock.action.view.ViewItem |
---|
getAction, getItem |
Constructor Detail |
---|
public AbstractDropDownHandler(S action, Dockable dockable, JMenuItem item)
action
- the action to observedockable
- the Dockable
for which the action is shown.item
- the item that represents the actionMethod Detail |
---|
public DropDownView getView()
null
public void addActionListener(ActionListener listener)
MenuViewItem
addActionListener
in interface MenuViewItem<JComponent>
listener
- the new listenerpublic boolean isSelectable()
DropDownViewItem
false
.
isSelectable
in interface DropDownViewItem
public boolean isTriggerable(boolean selected)
DropDownViewItem
isTriggerable
in interface DropDownViewItem
selected
- if true
, then this item is currently shown
directly on the main button, otherwise it is in the drop-down menu.
true
if the item can be triggeredpublic void removeActionListener(ActionListener listener)
MenuViewItem
removeActionListener
in interface MenuViewItem<JComponent>
listener
- the listener to removepublic void setView(DropDownView view)
DropDownViewItem
setView
in interface DropDownViewItem
view
- the view, might be null
public void bind()
AbstractMenuHandler
bind
in interface ViewItem<JComponent>
bind
in class AbstractMenuHandler<JMenuItem,S extends StandardDropDownItemAction>
public void unbind()
AbstractMenuHandler
unbind
in interface ViewItem<JComponent>
unbind
in class AbstractMenuHandler<JMenuItem,S extends StandardDropDownItemAction>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |