Package io.keikaiex.ui.impl
Class UndoableActionManagerImpl
- java.lang.Object
-
- io.keikaiex.ui.impl.UndoableActionManagerImpl
-
- All Implemented Interfaces:
UndoableActionManager,Serializable
public class UndoableActionManagerImpl extends Object implements UndoableActionManager, Serializable
default undoable action manager- Author:
- dennis
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description UndoableActionManagerImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidbind(Spreadsheet spreadsheet)Will be called when a manager createvoidclear()clear the historyvoiddoAction(UndoableAction action)Do the action and put it into historyStringgetRedoLabel()Get redo label, only available ifUndoableActionManager.isRedoable()StringgetUndoLabel()Get undo label, only available ifUndoableActionManager.isUndoable()booleanisRedoable()Is redoablebooleanisUndoable()Is undoablevoidredoAction()redo the last undo action, only availabel ifUndoableActionManager.isRedoable()voidsetMaxHsitorySize(int size)Sets the maximun history sizevoidundoAction()undo last action, only available ifUndoableActionManager.isUndoable()
-
-
-
Method Detail
-
doAction
public void doAction(UndoableAction action)
Description copied from interface:UndoableActionManagerDo the action and put it into history- Specified by:
doActionin interfaceUndoableActionManager
-
isUndoable
public boolean isUndoable()
Description copied from interface:UndoableActionManagerIs undoable- Specified by:
isUndoablein interfaceUndoableActionManager- Returns:
-
getUndoLabel
public String getUndoLabel()
Description copied from interface:UndoableActionManagerGet undo label, only available ifUndoableActionManager.isUndoable()- Specified by:
getUndoLabelin interfaceUndoableActionManager- Returns:
-
undoAction
public void undoAction()
Description copied from interface:UndoableActionManagerundo last action, only available ifUndoableActionManager.isUndoable()- Specified by:
undoActionin interfaceUndoableActionManager
-
isRedoable
public boolean isRedoable()
Description copied from interface:UndoableActionManagerIs redoable- Specified by:
isRedoablein interfaceUndoableActionManager- Returns:
-
getRedoLabel
public String getRedoLabel()
Description copied from interface:UndoableActionManagerGet redo label, only available ifUndoableActionManager.isRedoable()- Specified by:
getRedoLabelin interfaceUndoableActionManager- Returns:
-
redoAction
public void redoAction()
Description copied from interface:UndoableActionManagerredo the last undo action, only availabel ifUndoableActionManager.isRedoable()- Specified by:
redoActionin interfaceUndoableActionManager
-
clear
public void clear()
Description copied from interface:UndoableActionManagerclear the history- Specified by:
clearin interfaceUndoableActionManager
-
setMaxHsitorySize
public void setMaxHsitorySize(int size)
Description copied from interface:UndoableActionManagerSets the maximun history size- Specified by:
setMaxHsitorySizein interfaceUndoableActionManager
-
bind
public void bind(Spreadsheet spreadsheet)
Description copied from interface:UndoableActionManagerWill be called when a manager create- Specified by:
bindin interfaceUndoableActionManager
-
-