diff options
author | Kevin Ottens <kevin.ottens.qnx@kdab.com> | 2012-05-03 11:37:23 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-05-04 14:16:59 +0200 |
commit | e8df0eaa0158fcb2c4bf3f7aba544cedf107a113 (patch) | |
tree | 056683aade0fee9847c8fb5b6c177b77f0430a9e /src/plugins/sensors/blackberry/main.cpp | |
parent | 0cadbe2057f47e6bb4c72441b8f62ef574125e6b (diff) |
Add support for the pressure sensor
Change-Id: I3b58ead1b24391ead4577777387dce44245e28a0
Reviewed-by: Tennessee Carmel-Veilleux <tcarmelveilleux@rim.com>
Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
Reviewed-by: Lincoln Ramsay <lincoln.ramsay@nokia.com>
Diffstat (limited to 'src/plugins/sensors/blackberry/main.cpp')
-rw-r--r-- | src/plugins/sensors/blackberry/main.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/plugins/sensors/blackberry/main.cpp b/src/plugins/sensors/blackberry/main.cpp index 61ec0cd4..0d264e5c 100644 --- a/src/plugins/sensors/blackberry/main.cpp +++ b/src/plugins/sensors/blackberry/main.cpp @@ -45,6 +45,7 @@ #include "bblightsensor.h" #include "bbmagnetometer.h" #include "bborientationsensor.h" +#include "bbpressuresensor.h" #include "bbproximitysensor.h" #include "bbrotationsensor.h" #include "bbtemperaturesensor.h" @@ -59,6 +60,7 @@ static const char *bbIRProximitySensorId = "bbIRProximitySensor"; static const char *bbLightSensorId = "bbLightSensor"; static const char *bbMagnetometerId = "bbMagnetometer"; static const char *bbOrientationSensorId = "bbOrientationSensor"; +static const char *bbPressureSensorId = "bbPressureSensor"; static const char *bbProximitySensorId = "bbProximitySensor"; static const char *bbRotationSensorId = "bbRotationSensor"; static const char *bbTemperatureSensorId = "bbTemperatureSensorId"; @@ -86,6 +88,8 @@ public: QSensorManager::registerBackend("QMagnetometer", bbMagnetometerId, this); if (sensorSupported(BbOrientationSensor::devicePath())) QSensorManager::registerBackend("QOrientationSensor", bbOrientationSensorId, this); + if (sensorSupported(BbPressureSensor::devicePath())) + QSensorManager::registerBackend("BbPressureSensor", bbPressureSensorId, this); if (sensorSupported(BbProximitySensor::devicePath())) QSensorManager::registerBackend("QProximitySensor", bbProximitySensorId, this); if (sensorSupported(BbRotationSensor::devicePath())) @@ -111,6 +115,8 @@ public: backend = new BbMagnetometer(sensor); if (sensor->identifier() == bbOrientationSensorId) backend = new BbOrientationSensor(sensor); + if (sensor->identifier() == bbPressureSensorId) + backend = new BbPressureSensor(sensor); if (sensor->identifier() == bbProximitySensorId) backend = new BbProximitySensor(sensor); if (sensor->identifier() == bbRotationSensorId) |