Change input focus before unmapping