drag and drop with undo/redo