projects
/
platform
/
upstream
/
efl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
815d452
)
eeze/sensor/tizen: USe enum sentinel to iterate over sensor types.
author
Stefan Schmidt
<s.schmidt@samsung.com>
Wed, 3 Apr 2013 15:23:33 +0000
(16:23 +0100)
committer
Stefan Schmidt
<s.schmidt@samsung.com>
Wed, 3 Apr 2013 16:14:20 +0000
(17:14 +0100)
With the newer version we now have a sentinel that marks the last item of the enum.
src/modules/eeze/sensor/tizen/tizen.c
patch
|
blob
|
history
diff --git
a/src/modules/eeze/sensor/tizen/tizen.c
b/src/modules/eeze/sensor/tizen/tizen.c
index
b22bf63
..
603cc7b
100644
(file)
--- a/
src/modules/eeze/sensor/tizen/tizen.c
+++ b/
src/modules/eeze/sensor/tizen/tizen.c
@@
-769,8
+769,7
@@
eeze_sensor_tizen_sensors_find(void)
sensor_type_e type;
bool supported = 0;
- /* FIXME: Make this safe against changes in the enum. But how? */
- for (type = SENSOR_ACCELEROMETER; type <= SENSOR_MOTION_FACEDOWN; type++)
+ for (type = SENSOR_ACCELEROMETER; type <= SENSOR_LAST; type++)
{
sensor_is_supported(type, &supported);
if (supported)