diff options
author | Amaury Pouly <amaury.pouly@gmail.com> | 2013-09-05 20:35:51 +0200 |
---|---|---|
committer | Amaury Pouly <amaury.pouly@gmail.com> | 2013-09-05 20:35:51 +0200 |
commit | 1165a0882349ce1f1a426c642062dc06d0019265 (patch) | |
tree | be471ad1b96280801f893142ed9d279631e5008a | |
parent | df6eb82f5156256e1999374ce9b1a159610ff9a0 (diff) | |
download | rockbox-1165a0882349ce1f1a426c642062dc06d0019265.tar.gz rockbox-1165a0882349ce1f1a426c642062dc06d0019265.zip |
fix red
Change-Id: Ibca5879553a87e77014f850308d9b54cc339d474
-rw-r--r-- | firmware/SOURCES | 2 | ||||
-rw-r--r-- | firmware/drivers/touchscreen.c | 2 | ||||
-rw-r--r-- | firmware/export/touchscreen.h | 2 | ||||
-rw-r--r-- | firmware/target/hosted/sdl/button-sdl.c | 2 | ||||
-rw-r--r-- | uisimulator/common/stubs.c | 4 |
5 files changed, 9 insertions, 3 deletions
diff --git a/firmware/SOURCES b/firmware/SOURCES index 0210abe2f7..f7bd4ed974 100644 --- a/firmware/SOURCES +++ b/firmware/SOURCES | |||
@@ -1735,6 +1735,6 @@ thread.c | |||
1735 | 1735 | ||
1736 | #endif /* defined(SIMULATOR) */ | 1736 | #endif /* defined(SIMULATOR) */ |
1737 | 1737 | ||
1738 | #if defined(HAVE_TOUCHPAD) | 1738 | #if defined(HAVE_TOUCHPAD) && !defined(HAS_BUTTON_HOLD) |
1739 | drivers/touchpad.c | 1739 | drivers/touchpad.c |
1740 | #endif | 1740 | #endif |
diff --git a/firmware/drivers/touchscreen.c b/firmware/drivers/touchscreen.c index 8ce2400ca2..42ddf7ec47 100644 --- a/firmware/drivers/touchscreen.c +++ b/firmware/drivers/touchscreen.c | |||
@@ -172,6 +172,7 @@ enum touchscreen_mode touchscreen_get_mode(void) | |||
172 | return current_mode; | 172 | return current_mode; |
173 | } | 173 | } |
174 | 174 | ||
175 | #ifndef HAS_BUTTON_HOLD | ||
175 | void touchscreen_enable(bool en) | 176 | void touchscreen_enable(bool en) |
176 | { | 177 | { |
177 | if(en != touch_enabled) | 178 | if(en != touch_enabled) |
@@ -185,6 +186,7 @@ bool touchscreen_is_enabled(void) | |||
185 | { | 186 | { |
186 | return touch_enabled; | 187 | return touch_enabled; |
187 | } | 188 | } |
189 | #endif | ||
188 | 190 | ||
189 | #if ((CONFIG_PLATFORM & PLATFORM_ANDROID) == 0) | 191 | #if ((CONFIG_PLATFORM & PLATFORM_ANDROID) == 0) |
190 | /* android has an API for this */ | 192 | /* android has an API for this */ |
diff --git a/firmware/export/touchscreen.h b/firmware/export/touchscreen.h index 7421fe0b33..4aecb0310a 100644 --- a/firmware/export/touchscreen.h +++ b/firmware/export/touchscreen.h | |||
@@ -52,7 +52,9 @@ void touchscreen_disable_mapping(void); | |||
52 | void touchscreen_reset_mapping(void); | 52 | void touchscreen_reset_mapping(void); |
53 | int touchscreen_get_scroll_threshold(void); | 53 | int touchscreen_get_scroll_threshold(void); |
54 | void touchscreen_enable(bool en); | 54 | void touchscreen_enable(bool en); |
55 | #ifndef HAS_BUTTON_HOLD | ||
55 | void touchscreen_enable_device(bool en); | 56 | void touchscreen_enable_device(bool en); |
56 | bool touchscreen_is_enabled(void); | 57 | bool touchscreen_is_enabled(void); |
58 | #endif | ||
57 | 59 | ||
58 | #endif /* __TOUCHSCREEN_INCLUDE_H_ */ | 60 | #endif /* __TOUCHSCREEN_INCLUDE_H_ */ |
diff --git a/firmware/target/hosted/sdl/button-sdl.c b/firmware/target/hosted/sdl/button-sdl.c index f69c0a509b..eb4869ae25 100644 --- a/firmware/target/hosted/sdl/button-sdl.c +++ b/firmware/target/hosted/sdl/button-sdl.c | |||
@@ -393,7 +393,9 @@ static void button_event(int key, bool pressed) | |||
393 | #endif | 393 | #endif |
394 | default: | 394 | default: |
395 | #ifdef HAVE_TOUCHSCREEN | 395 | #ifdef HAVE_TOUCHSCREEN |
396 | # ifndef HAS_BUTTON_HOLD | ||
396 | if(touchscreen_is_enabled()) | 397 | if(touchscreen_is_enabled()) |
398 | # endif | ||
397 | new_btn = key_to_touch(key, mouse_coords); | 399 | new_btn = key_to_touch(key, mouse_coords); |
398 | if (!new_btn) | 400 | if (!new_btn) |
399 | #endif | 401 | #endif |
diff --git a/uisimulator/common/stubs.c b/uisimulator/common/stubs.c index 54ab6be76f..18f60ce6b3 100644 --- a/uisimulator/common/stubs.c +++ b/uisimulator/common/stubs.c | |||
@@ -382,14 +382,14 @@ void touchpad_set_sensitivity(int level) | |||
382 | } | 382 | } |
383 | #endif | 383 | #endif |
384 | 384 | ||
385 | #if defined(HAVE_TOUCHSCREEN) && !defined HAS_BUTTON_HOLD | 385 | #if defined(HAVE_TOUCHSCREEN) && !defined(HAS_BUTTON_HOLD) |
386 | void touchscreen_enable_device(bool en) | 386 | void touchscreen_enable_device(bool en) |
387 | { | 387 | { |
388 | (void)en; | 388 | (void)en; |
389 | } | 389 | } |
390 | #endif | 390 | #endif |
391 | 391 | ||
392 | #if defined(HAVE_TOUCHPAD) && !defined HAS_BUTTON_HOLD | 392 | #if defined(HAVE_TOUCHPAD) && !defined(HAS_BUTTON_HOLD) |
393 | void touchpad_enable_device(bool en) | 393 | void touchpad_enable_device(bool en) |
394 | { | 394 | { |
395 | (void)en; | 395 | (void)en; |