summaryrefslogtreecommitdiffstats
path: root/services/sensorservice
diff options
context:
space:
mode:
authorEthan Chen <intervigil@gmail.com>2015-04-23 17:27:36 -0700
committerGerrit Code Review <gerrit@cyanogenmod.org>2015-11-07 19:17:27 -0800
commitb53d92c3eb9319dbf725b3e59b3c52acfa6d77f0 (patch)
tree01834411aaf58fc082214e2e2d406e5154f18887 /services/sensorservice
parent911c7f3338fb1737dae3daddbf3735cc84786e11 (diff)
downloadframeworks_native-b53d92c3eb9319dbf725b3e59b3c52acfa6d77f0.zip
frameworks_native-b53d92c3eb9319dbf725b3e59b3c52acfa6d77f0.tar.gz
frameworks_native-b53d92c3eb9319dbf725b3e59b3c52acfa6d77f0.tar.bz2
sensorservice: Don't replace HAL orientation sensor
* Previously HAL orientation sensor would always be replaced if the HAL did not provide a rotation vector sensor as well. Practically no HAL does, so the virtual sensor would always replace it. * Add the virtual sensor only if the HAL does not provide it. Change-Id: I50ad2cd6c60b53eddc4c6854997ec2e3dbff0d1a
Diffstat (limited to 'services/sensorservice')
-rw-r--r--services/sensorservice/SensorService.cpp4
1 files changed, 0 insertions, 4 deletions
diff --git a/services/sensorservice/SensorService.cpp b/services/sensorservice/SensorService.cpp
index 2d35fe9..9c67be2 100644
--- a/services/sensorservice/SensorService.cpp
+++ b/services/sensorservice/SensorService.cpp
@@ -149,10 +149,6 @@ void SensorService::onFirstRef()
if (orientationIndex == -1) {
// some sensor HALs don't provide an orientation sensor.
mUserSensorList.add(aSensor);
- } else {
- // if we are doing our own rotation-vector, also add
- // the orientation sensor and remove the HAL provided one.
- mUserSensorList.replaceAt(aSensor, orientationIndex);
}
}