Fixed Undo/Redo operations