Added undo/redo for move function.