summaryrefslogtreecommitdiff
path: root/apps/keymaps
diff options
context:
space:
mode:
authorMartin Scarratt <mmmm@rockbox.org>2006-08-18 10:07:27 +0000
committerMartin Scarratt <mmmm@rockbox.org>2006-08-18 10:07:27 +0000
commitd75fedf960985efe1bacaf77ab339b1b3d07fb9c (patch)
treed448eecaf8c8c72a9e48e47b78d66c3ea4d979ba /apps/keymaps
parent155c55331c5e3333c36eec7db9db015cf42acbf5 (diff)
downloadrockbox-d75fedf960985efe1bacaf77ab339b1b3d07fb9c.tar.gz
rockbox-d75fedf960985efe1bacaf77ab339b1b3d07fb9c.zip
I-River Remote button support for yes/no screen. Also H1xx buttons = H3xx buttons for bookmarks.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10645 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/keymaps')
-rw-r--r--apps/keymaps/keymap-h1x0_h3x0.c40
1 files changed, 19 insertions, 21 deletions
diff --git a/apps/keymaps/keymap-h1x0_h3x0.c b/apps/keymaps/keymap-h1x0_h3x0.c
index 311ae89ea8..1e88b7935c 100644
--- a/apps/keymaps/keymap-h1x0_h3x0.c
+++ b/apps/keymaps/keymap-h1x0_h3x0.c
@@ -158,7 +158,6 @@ const struct button_mapping button_context_settingsgraphical[] = {
158 158
159const struct button_mapping button_context_yesno[] = { 159const struct button_mapping button_context_yesno[] = {
160 { ACTION_YESNO_ACCEPT, BUTTON_SELECT, BUTTON_NONE }, 160 { ACTION_YESNO_ACCEPT, BUTTON_SELECT, BUTTON_NONE },
161 { ACTION_YESNO_ACCEPT, BUTTON_RC_ON, BUTTON_NONE },
162 LAST_ITEM_IN_LIST 161 LAST_ITEM_IN_LIST
163}; /* button_context_settings_yesno */ 162}; /* button_context_settings_yesno */
164 163
@@ -267,6 +266,11 @@ const struct button_mapping button_context_settingsgraphical_h100lcdremote[] =
267 LAST_ITEM_IN_LIST 266 LAST_ITEM_IN_LIST
268}; /* button_context_settingsgraphical */ 267}; /* button_context_settingsgraphical */
269 268
269const struct button_mapping button_context_yesno_h100lcdremote[] = {
270 { ACTION_YESNO_ACCEPT, BUTTON_RC_MENU, BUTTON_NONE },
271 LAST_ITEM_IN_LIST
272}; /* button_context_settings_yesno */
273
270const struct button_mapping button_context_bmark_h100lcdremote[] = { 274const struct button_mapping button_context_bmark_h100lcdremote[] = {
271 { ACTION_BMARK_DELETE, BUTTON_RC_REC, BUTTON_NONE }, 275 { ACTION_BMARK_DELETE, BUTTON_RC_REC, BUTTON_NONE },
272 { ACTION_STD_OK, BUTTON_RC_MENU, BUTTON_NONE }, 276 { ACTION_STD_OK, BUTTON_RC_MENU, BUTTON_NONE },
@@ -312,24 +316,14 @@ const struct button_mapping button_context_listtree_h300lcdremote[] = {
312 316
313}; /* button_context_listtree_h300lcdremote */ 317}; /* button_context_listtree_h300lcdremote */
314 318
315const struct button_mapping button_context_settingsgraphical_h300lcdremote[] = { 319const struct button_mapping *button_context_settingsgraphical_h300lcdremote =
316 { ACTION_SETTINGS_INC, BUTTON_RC_FF, BUTTON_NONE }, 320 button_context_settingsgraphical_h100lcdremote;
317 { ACTION_SETTINGS_INCREPEAT, BUTTON_RC_FF|BUTTON_REPEAT, BUTTON_NONE }, 321
318 { ACTION_SETTINGS_DEC, BUTTON_RC_REW, BUTTON_NONE }, 322const struct button_mapping *button_context_yesno_h300lcdremote =
319 { ACTION_SETTINGS_DECREPEAT, BUTTON_RC_REW|BUTTON_REPEAT, BUTTON_NONE }, 323 button_context_yesno_h100lcdremote;
320 { ACTION_STD_PREV, BUTTON_RC_VOL_UP, BUTTON_NONE },
321 { ACTION_STD_PREVREPEAT, BUTTON_RC_VOL_UP|BUTTON_REPEAT, BUTTON_NONE },
322 { ACTION_STD_NEXT, BUTTON_RC_VOL_DOWN, BUTTON_NONE },
323 { ACTION_STD_NEXTREPEAT, BUTTON_RC_VOL_DOWN|BUTTON_REPEAT, BUTTON_NONE },
324
325 LAST_ITEM_IN_LIST
326}; /* button_context_settingsgraphical */
327 324
328const struct button_mapping button_context_bmark_h300lcdremote[] = { 325const struct button_mapping *button_context_bmark_h300lcdremote =
329 { ACTION_BMARK_DELETE, BUTTON_RC_REC, BUTTON_NONE }, 326 button_context_bmark_h100lcdremote;
330 { ACTION_STD_OK, BUTTON_RC_MENU, BUTTON_NONE },
331 LAST_ITEM_IN_LIST__NEXTLIST(CONTEXT_SETTINGSGRAPHICAL),
332}; /* button_context_settings_bmark */
333 327
334const struct button_mapping *button_context_settings_h300lcdremote = 328const struct button_mapping *button_context_settings_h300lcdremote =
335 button_context_settings_h100lcdremote; 329 button_context_settings_h100lcdremote;
@@ -347,6 +341,7 @@ static const struct button_mapping
347 *remote_button_context_listtree = button_context_listtree_h100lcdremote, 341 *remote_button_context_listtree = button_context_listtree_h100lcdremote,
348 *remote_button_context_settings = button_context_settings_h100lcdremote, 342 *remote_button_context_settings = button_context_settings_h100lcdremote,
349 *remote_button_context_settingsgraphical = button_context_settingsgraphical_h100lcdremote, 343 *remote_button_context_settingsgraphical = button_context_settingsgraphical_h100lcdremote,
344 *remote_button_context_yesno = button_context_yesno_h100lcdremote,
350 *remote_button_context_bmark = button_context_bmark_h100lcdremote; 345 *remote_button_context_bmark = button_context_bmark_h100lcdremote;
351 346
352static int _remote_type = 0; 347static int _remote_type = 0;
@@ -362,6 +357,7 @@ static void remap_remote(void)
362 remote_button_context_listtree = NULL; 357 remote_button_context_listtree = NULL;
363 remote_button_context_settings = NULL; 358 remote_button_context_settings = NULL;
364 remote_button_context_settingsgraphical = NULL; 359 remote_button_context_settingsgraphical = NULL;
360 remote_button_context_yesno = NULL;
365 remote_button_context_bmark = NULL; 361 remote_button_context_bmark = NULL;
366 break; 362 break;
367 case REMOTETYPE_H100_LCD: 363 case REMOTETYPE_H100_LCD:
@@ -370,6 +366,7 @@ static void remap_remote(void)
370 remote_button_context_listtree = button_context_listtree_h100lcdremote; 366 remote_button_context_listtree = button_context_listtree_h100lcdremote;
371 remote_button_context_settings = button_context_settings_h100lcdremote; 367 remote_button_context_settings = button_context_settings_h100lcdremote;
372 remote_button_context_settingsgraphical = button_context_settingsgraphical_h100lcdremote; 368 remote_button_context_settingsgraphical = button_context_settingsgraphical_h100lcdremote;
369 remote_button_context_yesno = button_context_yesno_h100lcdremote;
373 remote_button_context_bmark = button_context_bmark_h100lcdremote; 370 remote_button_context_bmark = button_context_bmark_h100lcdremote;
374 break; 371 break;
375 case REMOTETYPE_H300_LCD: 372 case REMOTETYPE_H300_LCD:
@@ -378,6 +375,7 @@ static void remap_remote(void)
378 remote_button_context_listtree = button_context_listtree_h300lcdremote; 375 remote_button_context_listtree = button_context_listtree_h300lcdremote;
379 remote_button_context_settings = button_context_settings_h300lcdremote; 376 remote_button_context_settings = button_context_settings_h300lcdremote;
380 remote_button_context_settingsgraphical = button_context_settingsgraphical_h300lcdremote; 377 remote_button_context_settingsgraphical = button_context_settingsgraphical_h300lcdremote;
378 remote_button_context_yesno = button_context_yesno_h300lcdremote;
381 remote_button_context_bmark = button_context_bmark_h300lcdremote; 379 remote_button_context_bmark = button_context_bmark_h300lcdremote;
382 break; 380 break;
383 case REMOTETYPE_H300_NONLCD: /* FIXME: add its tables */ 381 case REMOTETYPE_H300_NONLCD: /* FIXME: add its tables */
@@ -386,6 +384,7 @@ static void remap_remote(void)
386 remote_button_context_listtree = button_context_listtree_h300lcdremote; 384 remote_button_context_listtree = button_context_listtree_h300lcdremote;
387 remote_button_context_settings = button_context_settings_h300lcdremote; 385 remote_button_context_settings = button_context_settings_h300lcdremote;
388 remote_button_context_settingsgraphical = button_context_settingsgraphical_h300lcdremote; 386 remote_button_context_settingsgraphical = button_context_settingsgraphical_h300lcdremote;
387 remote_button_context_yesno = button_context_yesno_h300lcdremote;
389 remote_button_context_bmark = button_context_bmark_h300lcdremote; 388 remote_button_context_bmark = button_context_bmark_h300lcdremote;
390 break; 389 break;
391 } 390 }
@@ -418,11 +417,10 @@ const struct button_mapping* get_context_mapping_remote(int context)
418 return remote_button_context_listtree; 417 return remote_button_context_listtree;
419 case CONTEXT_SETTINGSGRAPHICAL: 418 case CONTEXT_SETTINGSGRAPHICAL:
420 return remote_button_context_settingsgraphical; 419 return remote_button_context_settingsgraphical;
420 case CONTEXT_YESNOSCREEN:
421 return remote_button_context_yesno;
421 case CONTEXT_BOOKMARKSCREEN: 422 case CONTEXT_BOOKMARKSCREEN:
422 return remote_button_context_bmark; 423 return remote_button_context_bmark;
423
424 case CONTEXT_YESNOSCREEN:
425 ; /* fall out of the switch */
426 } 424 }
427 return remote_button_context_std; 425 return remote_button_context_std;
428} 426}