Android: Don't abort when null Java Sensor
SensorManager::description() and getMaximumRange() called
methods on the QJniObject returned by javaSensor() without
checking it. On some devices SensorManager.getDefaultSensor()
returns null for a type that the NDK sensor list reports, so
JNI aborted the process in GetMethodID() as soon as
QSensor::start() created the backend.
Return an invalid object from javaSensor() in that case, and
fall back to a description without the Java sensor version and
to a maximum range of 0, which the proximity backend already
handles.
Fixes: QTBUG-150277
Pick-to: 6.12 6.11 6.8 6.5
Change-Id: I771d8b2698e91274d4a4a7210c41a9845722c35d
Reviewed-by: Lorn Potter <lorn.potter@qt.io>