summaryrefslogtreecommitdiff
path: root/uisimulator
diff options
context:
space:
mode:
authorKarl Kurbjun <kkurbjun@gmail.com>2009-10-31 16:27:09 +0000
committerKarl Kurbjun <kkurbjun@gmail.com>2009-10-31 16:27:09 +0000
commit223eba732e99d869fa0f65f98153642bd8d058a6 (patch)
treef431c1ed91282f1fb8b9a8d4c61fee9b5e988904 /uisimulator
parent8aba665bdd28b0c2238511e17e9a1a5ea8043abf (diff)
downloadrockbox-223eba732e99d869fa0f65f98153642bd8d058a6.tar.gz
rockbox-223eba732e99d869fa0f65f98153642bd8d058a6.zip
Simulator: Fix scrollwheel targets without HAVE_WHEEL_ACCELERATION defined
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23438 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'uisimulator')
-rw-r--r--uisimulator/sdl/button.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/uisimulator/sdl/button.c b/uisimulator/sdl/button.c
index 3a6b9ce09f..da672f3c92 100644
--- a/uisimulator/sdl/button.c
+++ b/uisimulator/sdl/button.c
@@ -1243,10 +1243,16 @@ void button_event(int key, bool pressed)
1243 * implementation (look at button-e200.c for example if you are trying to 1243 * implementation (look at button-e200.c for example if you are trying to
1244 * figure out why using button_get_data needed a hack before). 1244 * figure out why using button_get_data needed a hack before).
1245 */ 1245 */
1246#if defined(BUTTON_SCROLL_FWD) && defined(BUTTON_SCROLL_BACK) 1246#if defined(HAVE_WHEEL_ACCELERATION)
1247 if((new_btn == BUTTON_SCROLL_FWD || new_btn == BUTTON_SCROLL_BACK) && 1247 if((new_btn == BUTTON_SCROLL_FWD || new_btn == BUTTON_SCROLL_BACK) &&
1248 pressed) 1248 pressed)
1249 { 1249 {
1250 /* Clear these buttons from the data - adding them to the queue is
1251 * handled in the scrollwheel drivers for the targets. They do not
1252 * store the scroll forward/back buttons in their button data for
1253 * the button_read call.
1254 */
1255 btn &= ~(BUTTON_SCROLL_FWD | BUTTON_SCROLL_BACK);
1250 queue_post(&button_queue, new_btn, 1<<24); 1256 queue_post(&button_queue, new_btn, 1<<24);
1251 } 1257 }
1252#endif 1258#endif