|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jhotdraw.util.UndoRedoActivity
public class UndoRedoActivity
An UndoRedoActivity can be used to turn a UndoActivity into a RedoActivity. In this case, the redo() method of an encapsulated activity is called when the undo() is executed, and undo() when redo() is executed.
Method Summary | |
---|---|
static Undoable |
createUndoRedoActivity(Undoable toBeReversed)
|
FigureEnumeration |
getAffectedFigures()
|
int |
getAffectedFiguresCount()
|
DrawingView |
getDrawingView()
|
Undoable |
getReversedActivity()
|
boolean |
isRedoable()
Dispatch to isUndoable of the activity to be reversed. |
boolean |
isUndoable()
Dispatch to isRedoable of the activity to be reversed. |
boolean |
redo()
|
void |
release()
Releases all resources related to an undoable activity |
void |
setAffectedFigures(FigureEnumeration newAffectedFigures)
|
void |
setRedoable(boolean newIsRedoable)
Dispatch to setUndoable of the activity to be reversed. |
void |
setUndoable(boolean newIsUndoable)
Dispatch to setRedoable of the activity to be reversed. |
boolean |
undo()
Undo the activity |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public boolean undo()
undo
in interface Undoable
public boolean redo()
redo
in interface Undoable
public boolean isUndoable()
isUndoable
in interface Undoable
public void setUndoable(boolean newIsUndoable)
setUndoable
in interface Undoable
public boolean isRedoable()
isRedoable
in interface Undoable
public void setRedoable(boolean newIsRedoable)
setRedoable
in interface Undoable
public void setAffectedFigures(FigureEnumeration newAffectedFigures)
setAffectedFigures
in interface Undoable
public FigureEnumeration getAffectedFigures()
getAffectedFigures
in interface Undoable
public int getAffectedFiguresCount()
getAffectedFiguresCount
in interface Undoable
public DrawingView getDrawingView()
getDrawingView
in interface Undoable
public void release()
Undoable
release
in interface Undoable
public Undoable getReversedActivity()
public static Undoable createUndoRedoActivity(Undoable toBeReversed)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |