public class DelayUndoManager
extends javax.swing.undo.UndoManager
| Modifier and Type | Field and Description |
|---|---|
protected javax.swing.Timer |
_timer |
| Constructor and Description |
|---|
DelayUndoManager() |
DelayUndoManager(int delay) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
addEdit(javax.swing.undo.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, undoTopublic DelayUndoManager()
public DelayUndoManager(int delay)
public boolean isCacheEmpty()
public void commitCache()
public void addEditWithoutCaching()
public void discardCache()
public boolean addEdit(javax.swing.undo.UndoableEdit anEdit)
addEdit in interface javax.swing.undo.UndoableEditaddEdit in class javax.swing.undo.UndoManagerpublic boolean canUndo()
canUndo in interface javax.swing.undo.UndoableEditcanUndo in class javax.swing.undo.UndoManagerpublic boolean canRedo()
canRedo in interface javax.swing.undo.UndoableEditcanRedo in class javax.swing.undo.UndoManagerpublic void undo()
throws javax.swing.undo.CannotUndoException
undo in interface javax.swing.undo.UndoableEditundo in class javax.swing.undo.UndoManagerjavax.swing.undo.CannotUndoExceptionpublic void redo()
throws javax.swing.undo.CannotRedoException
redo in interface javax.swing.undo.UndoableEditredo in class javax.swing.undo.UndoManagerjavax.swing.undo.CannotRedoExceptionpublic void discardAllEdits()
discardAllEdits in class javax.swing.undo.UndoManager