|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.globalmentor.beans.BoundPropertyObject
com.guiseframework.event.GuiseBoundPropertyObject
com.guiseframework.coupler.AbstractCardCoupler
com.guiseframework.coupler.ActionCardCoupler
public class ActionCardCoupler
Associates an action control with a card in a card control.
When the action is initiated, the first displayed and enabled specified card within the card control will be selected.
When any of the the associated cards are selected, if the action implements Selectable the action will be selected.
If the card's constraints implement Displayable, the action will be displayed based upon the card constraints' displayed status.
If the card's constraints implement Enableable, the action will be enabled based upon the card constraints' enabled status.
If a card's constraints implement TaskCardConstraints and the action implements ActionValueControl and represents a TaskState value,
the action's contained value will reflect any changes in the card constraints task state.
If the action implements SelectActionControl its auto-select status will be turned off when installed.
This coupler is only functional when the given card is contained within a CardControl.
| Field Summary | |
|---|---|
static java.lang.String |
ACTION_PROPERTY
The bound property of the action. |
| Fields inherited from class com.guiseframework.coupler.AbstractCardCoupler |
|---|
CARD_PROPERTY, CARDS_PROPERTY |
| Fields inherited from class com.globalmentor.beans.BoundPropertyObject |
|---|
NO_PROPERTY_CHANGE_LISTENERS, NO_VETOABLE_CHANGE_LISTENERS |
| Constructor Summary | |
|---|---|
ActionCardCoupler()
Default constructor. |
|
ActionCardCoupler(ActionControl actionControl,
Component... cards)
Action and cards constructor. |
|
| Method Summary | |
|---|---|
ActionControl |
getAction()
|
void |
setAction(ActionControl newAction)
Sets the connected action. |
protected void |
updateDisplayed(boolean displayed)
Updates the current displayed status. |
protected void |
updateEnabled(boolean enabled)
Updates the current enabled status. |
protected void |
updateSelected(boolean selected)
Updates the current selected status. |
protected void |
updateTaskState(com.globalmentor.model.TaskState taskState)
Updates the current task state. |
| Methods inherited from class com.guiseframework.coupler.AbstractCardCoupler |
|---|
getCard, getCardControl, getCards, installCardConstraints, isCardSelectable, selectCard, selectCard, setCard, setCards, uninstallCardConstraints, updateDisplayed, updateEnabled, updateSelected, updateTaskState |
| Methods inherited from class com.guiseframework.event.GuiseBoundPropertyObject |
|---|
getSession |
| Methods inherited from class com.globalmentor.beans.BoundPropertyObject |
|---|
addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, addVetoableChangeListener, createPostponedPropertyChangeEvent, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, getForwardPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, getPropertyChangeSupport, getRepeatPropertyChangeListener, getRepeatVetoableChangeListener, getVetoableChangeListeners, getVetoableChangeListeners, getVetoableChangeSupport, hasPropertyChangeListeners, hasVetoableChangeListeners, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, removeVetoableChangeListener |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String ACTION_PROPERTY
| Constructor Detail |
|---|
public ActionCardCoupler()
public ActionCardCoupler(ActionControl actionControl,
Component... cards)
actionControl - The new action to connect to the card, or null if the action should not be coupled with a card.cards - The new cards to connect, if any.| Method Detail |
|---|
public ActionControl getAction()
null if the action is not coupled with a card.public void setAction(ActionControl newAction)
newAction - The new action to connect to the card, or null if the action should not be coupled with a card.ACTION_PROPERTYprotected void updateDisplayed(boolean displayed)
updateDisplayed in class AbstractCardCouplerdisplayed - The new displayed status.protected void updateEnabled(boolean enabled)
updateEnabled in class AbstractCardCouplerenabled - The new enabled status.protected void updateTaskState(com.globalmentor.model.TaskState taskState)
ActionValueControl containing a TaskState value, the action's value will be updated.
If no action is connected, no action occurs.
updateTaskState in class AbstractCardCouplertaskState - The new task state, or null if there is no task state.protected void updateSelected(boolean selected)
Selectable, its selected status will be updated.
If no action is connected, no action occurs.
updateSelected in class AbstractCardCouplerselected - The new selected status.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||