update cursor movement