public class DelayUndoManager extends UndoManager
| Modifier and Type | Field and Description |
|---|---|
protected Timer |
_timer |
editsRedoName, UndoName| Constructor and Description |
|---|
DelayUndoManager() |
DelayUndoManager(int delay) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
addEdit(UndoableEdit anEdit) |
void |
addEditWithoutCaching()
Calls super.addEdit without caching.
|
boolean |
canRedo()
Override to commit the cache before checking redo status.
|
boolean |
canUndo()
Override to commit the cache before checking undo status.
|
void |
commitCache()
Commits the cached edit.
|
void |
discardAllEdits() |
void |
discardCache() |
boolean |
isCacheEmpty()
Checks if there are pending edits in the DelayUndoManager.
|
void |
redo()
Override to commit the cache before redo.
|
void |
undo()
Override to commit the cache before undo.
|
canUndoOrRedo, editToBeRedone, editToBeUndone, end, getLimit, getRedoPresentationName, getUndoOrRedoPresentationName, getUndoPresentationName, redoTo, setLimit, toString, trimEdits, trimForLimit, undoableEditHappened, undoOrRedo, undoTodie, getPresentationName, isInProgress, isSignificant, lastEditreplaceEditprotected Timer _timer
public DelayUndoManager()
public DelayUndoManager(int delay)
public boolean isCacheEmpty()
public void commitCache()
public void addEditWithoutCaching()
public void discardCache()
public boolean addEdit(UndoableEdit anEdit)
addEdit in interface UndoableEditaddEdit in class UndoManagerpublic boolean canUndo()
canUndo in interface UndoableEditcanUndo in class UndoManagerpublic boolean canRedo()
canRedo in interface UndoableEditcanRedo in class UndoManagerpublic void undo()
throws CannotUndoException
undo in interface UndoableEditundo in class UndoManagerCannotUndoExceptionpublic void redo()
throws CannotRedoException
redo in interface UndoableEditredo in class UndoManagerCannotRedoExceptionpublic void discardAllEdits()
discardAllEdits in class UndoManagerCopyright © 2017. All rights reserved.