Fix build error when pointer lock is disabled.