better handling of missing mouse cursor