org.argouml.uml.diagram.ui
Class AbstractActionRadioMenuItem
java.lang.Object
javax.swing.AbstractAction
org.tigris.gef.undo.UndoableAction
org.argouml.uml.ui.UMLAction
org.argouml.uml.diagram.ui.AbstractActionRadioMenuItem
- All Implemented Interfaces:
- Action, ActionListener, Cloneable, EventListener, Serializable
- Direct Known Subclasses:
- ActionVisibilityPackage, ActionVisibilityPrivate, ActionVisibilityProtected, ActionVisibilityPublic
- abstract class AbstractActionRadioMenuItem
- extends UMLAction
This class adds the common algorithms
for handling multiple targets
for a radio menuitem to the UMLAction.
|
Method Summary |
void |
actionPerformed(ActionEvent e)
This action is performed on ALL targets. |
boolean |
isEnabled()
This action should be enabled when:
all targets are modelelements that support this radiobutton and
all targets have the radiobutton on the same item
(mixed is not yet supported, but could be if a tri-state
radiobutton is implemented). |
(package private) abstract void |
toggleValueOfTarget(Object t)
|
(package private) abstract Object |
valueOfTarget(Object t)
|
AbstractActionRadioMenuItem
public AbstractActionRadioMenuItem(String key,
boolean hasIcon)
isEnabled
public boolean isEnabled()
- This action should be enabled when:
- all targets are modelelements that support this radiobutton and
- all targets have the radiobutton on the same item
(mixed is not yet supported, but could be if a tri-state
radiobutton is implemented).
- Specified by:
isEnabled in interface Action- Overrides:
isEnabled in class UMLAction
- See Also:
Action.isEnabled()
valueOfTarget
abstract Object valueOfTarget(Object t)
- Parameters:
t - the target modelelement
- Returns:
- the UML element that represents the radiobutton
for this modelelement
actionPerformed
public final void actionPerformed(ActionEvent e)
- This action is performed on ALL targets.
- See Also:
ActionListener.actionPerformed(java.awt.event.ActionEvent)
toggleValueOfTarget
abstract void toggleValueOfTarget(Object t)
- Parameters:
t - the target modelelement