diff options
author | Nick Vaccaro <nvaccaro@google.com> | 2015-01-21 15:27:23 -0800 |
---|---|---|
committer | Nick Vaccaro <nvaccaro@google.com> | 2015-02-07 00:09:05 +0000 |
commit | 9bb99b1570a1715cce1d02a776c06f1596d61ecd (patch) | |
tree | 58dfc1f08be00356b5861812b99fc0d44198f40b | |
parent | d25be0ea48c775e4038163b546c9553e294d4fdc (diff) | |
download | frameworks_native-9bb99b1570a1715cce1d02a776c06f1596d61ecd.zip frameworks_native-9bb99b1570a1715cce1d02a776c06f1596d61ecd.tar.gz frameworks_native-9bb99b1570a1715cce1d02a776c06f1596d61ecd.tar.bz2 |
Add support for SENSOR_TYPE_WRIST_TILT_GESTURE
Change-Id: I7e5516de805618df41de0f9b06805002e32708c3
-rw-r--r-- | libs/gui/Sensor.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/libs/gui/Sensor.cpp b/libs/gui/Sensor.cpp index b4291bb..41a45fc 100644 --- a/libs/gui/Sensor.cpp +++ b/libs/gui/Sensor.cpp @@ -204,6 +204,13 @@ Sensor::Sensor(struct sensor_t const* hwSensor, int halVersion) mFlags |= SENSOR_FLAG_WAKE_UP; } break; + case SENSOR_TYPE_WRIST_TILT_GESTURE: + mStringType = SENSOR_STRING_TYPE_WRIST_TILT_GESTURE; + mFlags |= SENSOR_FLAG_SPECIAL_REPORTING_MODE; + if (halVersion < SENSORS_DEVICE_API_VERSION_1_3) { + mFlags |= SENSOR_FLAG_WAKE_UP; + } + break; default: // Only pipe the stringType, requiredPermission and flags for custom sensors. if (halVersion > SENSORS_DEVICE_API_VERSION_1_0 && hwSensor->stringType) { |