diff options
author | Frederik Gladhorn <frederik.gladhorn@digia.com> | 2014-06-26 17:26:03 +0200 |
---|---|---|
committer | Frederik Gladhorn <frederik.gladhorn@digia.com> | 2014-06-26 17:26:03 +0200 |
commit | 0520efecf2c8442e3a4870412243fd7cedb3c387 (patch) | |
tree | b83b360f21ca381828980b84ae47bfb727af3c59 | |
parent | 2701763c003e9d2cc59a936491ab2fa8b6ff7f74 (diff) | |
parent | 3690925021c60378bb1d21e9102f7f8aa8627716 (diff) | |
download | qtsensors-0520efecf2c8442e3a4870412243fd7cedb3c387.tar.gz qtsensors-0520efecf2c8442e3a4870412243fd7cedb3c387.tar.bz2 qtsensors-0520efecf2c8442e3a4870412243fd7cedb3c387.zip |
Merge remote-tracking branch 'origin/5.3' into dev
Conflicts:
.qmake.conf
Change-Id: I01306a5c0d34f85efdbc5f947add4dee0cccbf8e
6 files changed, 7 insertions, 7 deletions
diff --git a/src/plugins/sensors/winrt/winrtaccelerometer.cpp b/src/plugins/sensors/winrt/winrtaccelerometer.cpp index c8e8b26..16261c6 100644 --- a/src/plugins/sensors/winrt/winrtaccelerometer.cpp +++ b/src/plugins/sensors/winrt/winrtaccelerometer.cpp @@ -130,7 +130,7 @@ WinRtAccelerometer::WinRtAccelerometer(QSensor *sensor) } hr = factory->GetDefault(&d->sensor); - if (FAILED(hr)) { + if (FAILED(hr) || !d->sensor) { qCWarning(lcWinRtSensors) << "Unable to get default accelerometer." << qt_error_string(hr); sensorError(hr); diff --git a/src/plugins/sensors/winrt/winrtambientlightsensor.cpp b/src/plugins/sensors/winrt/winrtambientlightsensor.cpp index 18ee641..33bbac1 100644 --- a/src/plugins/sensors/winrt/winrtambientlightsensor.cpp +++ b/src/plugins/sensors/winrt/winrtambientlightsensor.cpp @@ -129,7 +129,7 @@ WinRtAmbientLightSensor::WinRtAmbientLightSensor(QSensor *sensor) } hr = factory->GetDefault(&d->sensor); - if (FAILED(hr)) { + if (FAILED(hr) || !d->sensor) { qCWarning(lcWinRtSensors) << "Unable to get default light sensor." << qt_error_string(hr); sensorError(hr); diff --git a/src/plugins/sensors/winrt/winrtcompass.cpp b/src/plugins/sensors/winrt/winrtcompass.cpp index bc2430f..6a678e2 100644 --- a/src/plugins/sensors/winrt/winrtcompass.cpp +++ b/src/plugins/sensors/winrt/winrtcompass.cpp @@ -150,8 +150,8 @@ WinRtCompass::WinRtCompass(QSensor *sensor) } hr = factory->GetDefault(&d->sensor); - if (FAILED(hr)) { - qCWarning(lcWinRtSensors) << "Unable to get default light sensor." + if (FAILED(hr) || !d->sensor) { + qCWarning(lcWinRtSensors) << "Unable to get default compass." << qt_error_string(hr); sensorError(hr); return; diff --git a/src/plugins/sensors/winrt/winrtgyroscope.cpp b/src/plugins/sensors/winrt/winrtgyroscope.cpp index dec6512..1e729a1 100644 --- a/src/plugins/sensors/winrt/winrtgyroscope.cpp +++ b/src/plugins/sensors/winrt/winrtgyroscope.cpp @@ -127,7 +127,7 @@ WinRtGyroscope::WinRtGyroscope(QSensor *sensor) } hr = factory->GetDefault(&d->sensor); - if (FAILED(hr)) { + if (FAILED(hr) || !d->sensor) { qCWarning(lcWinRtSensors) << "Unable to get default gyroscope sensor." << qt_error_string(hr); sensorError(hr); diff --git a/src/plugins/sensors/winrt/winrtorientationsensor.cpp b/src/plugins/sensors/winrt/winrtorientationsensor.cpp index 6d85e51..b8c7e81 100644 --- a/src/plugins/sensors/winrt/winrtorientationsensor.cpp +++ b/src/plugins/sensors/winrt/winrtorientationsensor.cpp @@ -135,7 +135,7 @@ WinRtOrientationSensor::WinRtOrientationSensor(QSensor *sensor) } hr = factory->GetDefault(&d->sensor); - if (FAILED(hr)) { + if (FAILED(hr) || !d->sensor) { qCWarning(lcWinRtSensors) << "Unable to get default orientation sensor." << qt_error_string(hr); sensorError(hr); diff --git a/src/plugins/sensors/winrt/winrtrotationsensor.cpp b/src/plugins/sensors/winrt/winrtrotationsensor.cpp index e4e3edc..576545e 100644 --- a/src/plugins/sensors/winrt/winrtrotationsensor.cpp +++ b/src/plugins/sensors/winrt/winrtrotationsensor.cpp @@ -125,7 +125,7 @@ WinRtRotationSensor::WinRtRotationSensor(QSensor *sensor) } hr = factory->GetDefault(&d->sensor); - if (FAILED(hr)) { + if (FAILED(hr) || !d->sensor) { qCWarning(lcWinRtSensors) << "Unable to get default rotation sensor." << qt_error_string(hr); sensorError(hr); |