summaryrefslogtreecommitdiff
path: root/apps/keymaps
diff options
context:
space:
mode:
authorBarry Wardell <rockbox@barrywardell.net>2007-11-11 16:00:33 +0000
committerBarry Wardell <rockbox@barrywardell.net>2007-11-11 16:00:33 +0000
commitc495cdae5926c9245d7c943c72a97206d4a0e22a (patch)
tree86afcd473d1c151ffd26fcb8e941be44a0bbbf53 /apps/keymaps
parent496027d8bb89ba6d503b544f5652f4d1683d43af (diff)
downloadrockbox-c495cdae5926c9245d7c943c72a97206d4a0e22a.zip
rockbox-c495cdae5926c9245d7c943c72a97206d4a0e22a.tar.gz
rockbox-c495cdae5926c9245d7c943c72a97206d4a0e22a.tar.bz2
rockbox-c495cdae5926c9245d7c943c72a97206d4a0e22a.tar.xz
FS#8046: H10 FM tuner support. Thanks to Przemyslaw Holubowski for doing the hard work in figuring out how to communicate with the tuner.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15578 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/keymaps')
-rw-r--r--apps/keymaps/keymap-h10.c23
1 files changed, 22 insertions, 1 deletions
diff --git a/apps/keymaps/keymap-h10.c b/apps/keymaps/keymap-h10.c
index 3e90f15..883b0d3 100644
--- a/apps/keymaps/keymap-h10.c
+++ b/apps/keymaps/keymap-h10.c
@@ -305,6 +305,26 @@ const struct button_mapping button_context_recscreen[] = {
LAST_ITEM_IN_LIST__NEXTLIST(CONTEXT_SETTINGS)
}; /* button_context_recscreen */
+static const struct button_mapping button_context_radio[] = {
+ { ACTION_FM_PRESET, BUTTON_RIGHT | BUTTON_REL, BUTTON_RIGHT },
+ { ACTION_FM_MENU, BUTTON_RIGHT | BUTTON_REPEAT, BUTTON_NONE },
+ { ACTION_FM_MODE, BUTTON_LEFT, BUTTON_NONE },
+ { ACTION_FM_STOP, BUTTON_PLAY | BUTTON_REPEAT, BUTTON_PLAY },
+ { ACTION_FM_EXIT, BUTTON_POWER, BUTTON_NONE },
+ { ACTION_FM_PLAY, BUTTON_PLAY | BUTTON_REL, BUTTON_PLAY },
+ { ACTION_SETTINGS_INC, BUTTON_SCROLL_UP, BUTTON_NONE },
+ { ACTION_SETTINGS_INCREPEAT, BUTTON_SCROLL_UP|BUTTON_REPEAT, BUTTON_NONE },
+ { ACTION_SETTINGS_DEC, BUTTON_SCROLL_DOWN, BUTTON_NONE },
+ { ACTION_SETTINGS_DECREPEAT, BUTTON_SCROLL_DOWN|BUTTON_REPEAT, BUTTON_NONE },
+ { ACTION_STD_PREV, BUTTON_REW, BUTTON_NONE },
+ { ACTION_STD_PREVREPEAT, BUTTON_REW|BUTTON_REPEAT, BUTTON_NONE },
+ { ACTION_STD_NEXT, BUTTON_FF, BUTTON_NONE },
+ { ACTION_STD_NEXTREPEAT, BUTTON_FF|BUTTON_REPEAT, BUTTON_NONE },
+
+ LAST_ITEM_IN_LIST
+
+};
+
static const struct button_mapping* get_context_mapping_remote( int context )
{
context ^= CONTEXT_REMOTE;
@@ -385,7 +405,8 @@ const struct button_mapping* get_context_mapping(int context)
return button_context_keyboard;
case CONTEXT_RECSCREEN:
return button_context_recscreen;
-
+ case CONTEXT_FM:
+ return button_context_radio;
default:
return button_context_standard;
}