summaryrefslogtreecommitdiffstats
path: root/apps/wps.h
diff options
context:
space:
mode:
authorMarcoen Hirschberg <marcoen@gmail.com>2005-06-12 16:10:17 +0000
committerMarcoen Hirschberg <marcoen@gmail.com>2005-06-12 16:10:17 +0000
commitc19e0f0d02fe1e87f24fc3037edd4e1566280d86 (patch)
treec8ba43b560b5a292c0783c40bce82c1019662564 /apps/wps.h
parent097444d07cf394919d7eba149dfe81161cd86453 (diff)
downloadrockbox-c19e0f0d02fe1e87f24fc3037edd4e1566280d86.tar.gz
rockbox-c19e0f0d02fe1e87f24fc3037edd4e1566280d86.zip
Add remote control support to tree and menu. Move defines from wps.c to wps.h
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@6692 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/wps.h')
-rw-r--r--apps/wps.h114
1 files changed, 114 insertions, 0 deletions
diff --git a/apps/wps.h b/apps/wps.h
index f218fdd277..668f9f6bbd 100644
--- a/apps/wps.h
+++ b/apps/wps.h
@@ -21,6 +21,119 @@
#include "id3.h"
#include "playlist.h"
+/* button definitions */
+#if CONFIG_KEYPAD == IRIVER_H100_PAD
+#define WPS_NEXT (BUTTON_RIGHT | BUTTON_REL)
+#define WPS_NEXT_PRE BUTTON_RIGHT
+#define WPS_PREV (BUTTON_LEFT | BUTTON_REL)
+#define WPS_PREV_PRE BUTTON_LEFT
+#define WPS_FFWD (BUTTON_RIGHT | BUTTON_REPEAT)
+#define WPS_REW (BUTTON_LEFT | BUTTON_REPEAT)
+#define WPS_INCVOL BUTTON_UP
+#define WPS_DECVOL BUTTON_DOWN
+#define WPS_PAUSE BUTTON_ON
+#define WPS_MENU (BUTTON_MODE | BUTTON_REL)
+#define WPS_MENU_PRE BUTTON_MODE
+#define WPS_BROWSE (BUTTON_SELECT | BUTTON_REL)
+#define WPS_BROWSE_PRE BUTTON_SELECT
+#define WPS_EXIT BUTTON_OFF
+#define WPS_KEYLOCK (BUTTON_MODE | BUTTON_DOWN)
+#define WPS_ID3 (BUTTON_MODE | BUTTON_ON)
+
+#define WPS_RC_NEXT BUTTON_RC_FF
+#define WPS_RC_PREV BUTTON_RC_REW
+#define WPS_RC_PAUSE BUTTON_RC_ON
+#define WPS_RC_INCVOL BUTTON_RC_VOL_UP
+#define WPS_RC_DECVOL BUTTON_RC_VOL_DOWN
+#define WPS_RC_EXIT BUTTON_RC_STOP
+
+
+#elif CONFIG_KEYPAD == RECORDER_PAD
+#define WPS_NEXT (BUTTON_RIGHT | BUTTON_REL)
+#define WPS_NEXT_PRE BUTTON_RIGHT
+#define WPS_PREV (BUTTON_LEFT | BUTTON_REL)
+#define WPS_PREV_PRE BUTTON_LEFT
+#define WPS_FFWD (BUTTON_RIGHT | BUTTON_REPEAT)
+#define WPS_REW (BUTTON_LEFT | BUTTON_REPEAT)
+#define WPS_INCVOL BUTTON_UP
+#define WPS_DECVOL BUTTON_DOWN
+#define WPS_PAUSE BUTTON_PLAY
+#define WPS_MENU (BUTTON_F1 | BUTTON_REL)
+#define WPS_MENU_PRE BUTTON_F1
+#define WPS_BROWSE (BUTTON_ON | BUTTON_REL)
+#define WPS_BROWSE_PRE BUTTON_ON
+#define WPS_EXIT BUTTON_OFF
+#define WPS_KEYLOCK (BUTTON_F1 | BUTTON_DOWN)
+#define WPS_ID3 (BUTTON_F1 | BUTTON_ON)
+
+#define WPS_RC_NEXT BUTTON_RC_RIGHT
+#define WPS_RC_PREV BUTTON_RC_LEFT
+#define WPS_RC_PAUSE BUTTON_RC_PLAY
+#define WPS_RC_INCVOL BUTTON_RC_VOL_UP
+#define WPS_RC_DECVOL BUTTON_RC_VOL_DOWN
+#define WPS_RC_EXIT BUTTON_RC_STOP
+
+#elif CONFIG_KEYPAD == PLAYER_PAD
+#define WPS_NEXT (BUTTON_RIGHT | BUTTON_REL)
+#define WPS_NEXT_PRE BUTTON_RIGHT
+#define WPS_PREV (BUTTON_LEFT | BUTTON_REL)
+#define WPS_PREV_PRE BUTTON_LEFT
+#define WPS_FFWD (BUTTON_RIGHT | BUTTON_REPEAT)
+#define WPS_REW (BUTTON_LEFT | BUTTON_REPEAT)
+#define WPS_INCVOL (BUTTON_MENU | BUTTON_RIGHT)
+#define WPS_DECVOL (BUTTON_MENU | BUTTON_LEFT)
+#define WPS_PAUSE BUTTON_PLAY
+#define WPS_MENU (BUTTON_MENU | BUTTON_REL)
+#define WPS_MENU_PRE BUTTON_MENU
+#define WPS_BROWSE (BUTTON_ON | BUTTON_REL)
+#define WPS_BROWSE_PRE BUTTON_ON
+#define WPS_EXIT BUTTON_STOP
+#define WPS_KEYLOCK (BUTTON_MENU | BUTTON_STOP)
+#define WPS_ID3 (BUTTON_MENU | BUTTON_ON)
+
+#define WPS_RC_NEXT BUTTON_RC_RIGHT
+#define WPS_RC_PREV BUTTON_RC_LEFT
+#define WPS_RC_PAUSE BUTTON_RC_PLAY
+#define WPS_RC_INCVOL BUTTON_RC_VOL_UP
+#define WPS_RC_DECVOL BUTTON_RC_VOL_DOWN
+#define WPS_RC_EXIT BUTTON_RC_STOP
+
+#elif CONFIG_KEYPAD == ONDIO_PAD
+#define WPS_NEXT (BUTTON_RIGHT | BUTTON_REL)
+#define WPS_NEXT_PRE BUTTON_RIGHT
+#define WPS_PREV (BUTTON_LEFT | BUTTON_REL)
+#define WPS_PREV_PRE BUTTON_LEFT
+#define WPS_FFWD (BUTTON_RIGHT | BUTTON_REPEAT)
+#define WPS_REW (BUTTON_LEFT | BUTTON_REPEAT)
+#define WPS_INCVOL BUTTON_UP
+#define WPS_DECVOL BUTTON_DOWN
+#define WPS_PAUSE BUTTON_OFF
+#define WPS_MENU (BUTTON_MENU | BUTTON_REPEAT)
+#define WPS_BROWSE (BUTTON_MENU | BUTTON_REL)
+#define WPS_BROWSE_PRE BUTTON_MENU
+#define WPS_KEYLOCK (BUTTON_MENU | BUTTON_DOWN)
+#define WPS_EXIT (BUTTON_OFF | BUTTON_REPEAT)
+
+#elif CONFIG_KEYPAD == GMINI100_PAD
+#define WPS_NEXT (BUTTON_RIGHT | BUTTON_REL)
+#define WPS_NEXT_PRE BUTTON_RIGHT
+#define WPS_PREV (BUTTON_LEFT | BUTTON_REL)
+#define WPS_PREV_PRE BUTTON_LEFT
+#define WPS_FFWD (BUTTON_RIGHT | BUTTON_REPEAT)
+#define WPS_REW (BUTTON_LEFT | BUTTON_REPEAT)
+#define WPS_INCVOL BUTTON_UP
+#define WPS_DECVOL BUTTON_DOWN
+#define WPS_PAUSE BUTTON_PLAY
+#define WPS_MENU (BUTTON_MENU | BUTTON_REL)
+#define WPS_MENU_PRE BUTTON_MENU
+#define WPS_BROWSE (BUTTON_ON | BUTTON_REL)
+#define WPS_BROWSE_PRE BUTTON_ON
+#define WPS_EXIT BUTTON_OFF
+#define WPS_KEYLOCK (BUTTON_MENU | BUTTON_DOWN)
+#define WPS_ID3 (BUTTON_MENU | BUTTON_ON)
+
+#endif
+
extern bool keys_locked;
extern bool wps_time_countup;
@@ -34,3 +147,4 @@ bool f3_screen(void);
#endif
#endif
+