set current cursor on main thread