mend the drag functions.