summaryrefslogtreecommitdiffstats
path: root/uisimulator
diff options
context:
space:
mode:
authorKarl Kurbjun <kkurbjun@gmail.com>2009-10-05 04:20:28 +0000
committerKarl Kurbjun <kkurbjun@gmail.com>2009-10-05 04:20:28 +0000
commit714b4aaaf830a1707463984ed74d8d94966b75dc (patch)
treef6074101fa403d31d5077000d610552da05f9e0f /uisimulator
parentfac05ab2f755318bb42ce0eca55eb4061358bad1 (diff)
downloadrockbox-714b4aaaf830a1707463984ed74d8d94966b75dc.tar.gz
rockbox-714b4aaaf830a1707463984ed74d8d94966b75dc.tar.bz2
rockbox-714b4aaaf830a1707463984ed74d8d94966b75dc.zip
Simulator buttons: Remove a hack and make brickmania work the same as on target.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22936 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'uisimulator')
-rw-r--r--uisimulator/sdl/button.c20
1 files changed, 7 insertions, 13 deletions
diff --git a/uisimulator/sdl/button.c b/uisimulator/sdl/button.c
index 5bda8a3ffd..ee0a24008b 100644
--- a/uisimulator/sdl/button.c
+++ b/uisimulator/sdl/button.c
@@ -1211,7 +1211,13 @@ void button_event(int key, bool pressed)
#ifdef HAVE_BUTTON_DATA
int button_read_device(int* data)
{
- (void)data;
+#if defined(HAVE_TOUCHSCREEN)
+ *data=mouse_coords;
+#else
+ /* pass scrollwheel acceleration to the button driver */
+ *data = 1<<24;
+#endif
+
#else
int button_read_device(void)
{
@@ -1264,19 +1270,7 @@ void mouse_tick_task(void)
printf("Mouse at: (%d, %d)\n", x, y);
}
}
-
-#endif
-
-intptr_t button_get_data_sdl(void)
-{
-#ifdef HAVE_TOUCHSCREEN
- /* pass the mouse coordinates to the button driver */
- return mouse_coords;
-#else
- /* pass scrollwheel acceleration to the button driver */
- return 1<<24;
#endif
-}
void button_init_sdl(void)
{