|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectbibliothek.gui.dock.action.AbstractDockActionSource
bibliothek.gui.dock.facile.action.KeyedActionSource
@FrameworkOnly public class KeyedActionSource
An action source using CDockable.getAction(String) to determine which
action to use. If getAction returns null, then
a default action can be used. This action source also allows to disable any
action.
| Field Summary |
|---|
| Fields inherited from class bibliothek.gui.dock.action.AbstractDockActionSource |
|---|
listeners |
| Constructor Summary | |
|---|---|
KeyedActionSource(CDockable dockable,
String key)
Creates a new action source |
|
| Method Summary | |
|---|---|
void |
addDockActionSourceListener(DockActionSourceListener listener)
Adds a listener to this source. |
void |
destroy()
Detaches the listeners this DockActionSource added to
other objects. |
DockAction |
getDefaultAction()
Gets the default action of this source. |
DockAction |
getDockAction(int index)
Gets the index'th DockAction of this source. |
int |
getDockActionCount()
Gets the number of DockActions which are
provided by this source. |
String |
getKey()
Gets the key which is used for calling CDockable.getAction(String) |
LocationHint |
getLocationHint()
Gets a hint where to put this source in relation to other sources. |
Iterator<DockAction> |
iterator()
|
void |
removeDockActionSourceListener(DockActionSourceListener listener)
Removes an earlier added listener. |
void |
setDefaultAction(DockAction defaultAction)
Sets the default action of this source. |
void |
setVisible(boolean visible)
Changes whether any actions are shown or not. |
| Methods inherited from class bibliothek.gui.dock.action.AbstractDockActionSource |
|---|
fireAdded, fireRemoved, indexOf |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public KeyedActionSource(CDockable dockable,
String key)
dockable - the element for which this source is usedkey - the key for calling CDockable.getAction(String)| Method Detail |
|---|
public String getKey()
CDockable.getAction(String)
nullpublic void addDockActionSourceListener(DockActionSourceListener listener)
DockActionSourceDockActionSourceListener should
be informed whenever some DockActions are added or
removed from this source.
addDockActionSourceListener in interface DockActionSourceaddDockActionSourceListener in class AbstractDockActionSourcelistener - The listenerpublic void removeDockActionSourceListener(DockActionSourceListener listener)
DockActionSource
removeDockActionSourceListener in interface DockActionSourceremoveDockActionSourceListener in class AbstractDockActionSourcelistener - The listener to removeDockActionSource.addDockActionSourceListener(DockActionSourceListener)public void destroy()
DockActionSource added to
other objects.
public void setVisible(boolean visible)
visible - the new statepublic void setDefaultAction(DockAction defaultAction)
CDockable.getAction(String) returns
null.
defaultAction - the default action, may be nullpublic DockAction getDefaultAction()
nullpublic DockAction getDockAction(int index)
DockActionSourceDockAction of this source.
index - The index of the action
public int getDockActionCount()
DockActionSourceDockActions which are
provided by this source.
DockActionspublic LocationHint getLocationHint()
DockActionSourceActionOffer can choose to ignore these hints, or interpret
them in an unexpected way.
public Iterator<DockAction> iterator()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||