More refactoring, added a start to the repositioning after dragging