com.anthonyeden.lib.gui
Class RedoAction

java.lang.Object
  extended byjavax.swing.AbstractAction
      extended bycom.anthonyeden.lib.gui.RedoAction
All Implemented Interfaces:
javax.swing.Action, java.awt.event.ActionListener, java.lang.Cloneable, java.util.EventListener, java.io.Serializable

public class RedoAction
extends javax.swing.AbstractAction

A UI action for redo.

Author:
Anthony Eden
See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
 
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SHORT_DESCRIPTION, SMALL_ICON
 
Constructor Summary
RedoAction(javax.swing.undo.UndoManager undoManager)
          Construct a new RedoAction which uses the given UndoManager for managing undos and redos.
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent e)
          Invoked when an ActionEvent occurs.
 void executeRedo()
          Execute the redo.
 void setUndoAction(UndoAction undoAction)
          Set the undo action.
 void updateRedoState()
          Update the redo state in the UndoManager.
 
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RedoAction

public RedoAction(javax.swing.undo.UndoManager undoManager)
Construct a new RedoAction which uses the given UndoManager for managing undos and redos.

Parameters:
undoManager - The UndoManager
Method Detail

setUndoAction

public void setUndoAction(UndoAction undoAction)
Set the undo action. Setting the undo action will allow the redo action to tell the undo action to update its state when a redo occurs.

Parameters:
undoAction - The undo action

executeRedo

public void executeRedo()
Execute the redo. This method is typically invoked when the Action is triggered. It may also be used programatically.


actionPerformed

public void actionPerformed(java.awt.event.ActionEvent e)
Invoked when an ActionEvent occurs.

Parameters:
e - The ActionEvent

updateRedoState

public void updateRedoState()
Update the redo state in the UndoManager.



Copyright (c) 2000-2003 Anthony Eden. All Rights Reserved.