public void Redo() { UndoRedoItem <T> top = (UndoRedoItem <T>)_redoStack.Pop(); top.Cmd.Execute(top); top.SwapOldAndNew(); _undoStack.Push(top); //RemoveChangeLog(top); }
public void Undo(bool canRedo) { UndoRedoItem <T> top = _undoStack.Pop(); top.Cmd.UnExecute(top); if (canRedo == true) { top.SwapOldAndNew(); _redoStack.Push(top); } //AddChangeLog(top); }