Class ViewAction
- java.lang.Object
-
- javax.swing.AbstractAction
-
- net.sf.gridarta.gui.map.viewaction.ViewAction
-
- All Implemented Interfaces:
java.awt.event.ActionListener,java.io.Serializable,java.lang.Cloneable,java.util.EventListener,javax.swing.Action
public class ViewAction extends javax.swing.AbstractActionAction to manage one edit type represented by oneNamedGameObjectMatcher.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ViewAction(@NotNull MapViewSettings mapViewSettings, @NotNull NamedGameObjectMatcher matcher)Creates a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidactionPerformed(@NotNull java.awt.event.ActionEvent e)@NotNull ViewActionclone()@NotNull java.awt.ComponentgetCheckBoxMenuItem()Returns the menu item for this action.@NotNull java.lang.StringgetName()Returns the name for sorting the menu entries.voidupdateAction()Update the action's state to match the current edit type settings.-
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
-
-
-
-
Constructor Detail
-
ViewAction
public ViewAction(@NotNull @NotNull MapViewSettings mapViewSettings, @NotNull @NotNull NamedGameObjectMatcher matcher)Creates a new instance.- Parameters:
mapViewSettings- the map view settings instancematcher- the matcher
-
-
Method Detail
-
getName
@NotNull public @NotNull java.lang.String getName()
Returns the name for sorting the menu entries.- Returns:
- the name
-
updateAction
public final void updateAction()
Update the action's state to match the current edit type settings.
-
actionPerformed
public void actionPerformed(@NotNull @NotNull java.awt.event.ActionEvent e)
-
getCheckBoxMenuItem
@NotNull public @NotNull java.awt.Component getCheckBoxMenuItem()
Returns the menu item for this action.- Returns:
- the menu item
-
clone
@NotNull public @NotNull ViewAction clone() throws java.lang.CloneNotSupportedException
- Overrides:
clonein classjavax.swing.AbstractAction- Throws:
java.lang.CloneNotSupportedException
-
-