handling pan on TheNewTaskDialog