Added logic for modifying the path of dragged object.