diff options
author | Marianne Arnold <pixelma@rockbox.org> | 2008-09-03 22:30:30 +0000 |
---|---|---|
committer | Marianne Arnold <pixelma@rockbox.org> | 2008-09-03 22:30:30 +0000 |
commit | 23ab966f6401fa7558200a70f411ac704b22555f (patch) | |
tree | f24aea6b4a55a1b456fe218bc3c43e9d4ba8f6ce /firmware/drivers | |
parent | 16b8817f9fc21f89cd989ebaa3910ab9198739ce (diff) | |
download | rockbox-23ab966f6401fa7558200a70f411ac704b22555f.tar.gz rockbox-23ab966f6401fa7558200a70f411ac704b22555f.zip |
C200: Also flip the function of the volume buttons when display flip is enabled. I think it is more consistent, especially when thinking of cases where these buttons are used for something else (e.g. left/right in brickmania). Taken from FS#8393 by Volker Mische - add him to CREDITS too.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@18404 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/drivers')
-rw-r--r-- | firmware/drivers/button.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/firmware/drivers/button.c b/firmware/drivers/button.c index 8ad93ae022..9dfebf6e38 100644 --- a/firmware/drivers/button.c +++ b/firmware/drivers/button.c | |||
@@ -438,6 +438,9 @@ static int button_flip(int button) | |||
438 | #if CONFIG_KEYPAD == RECORDER_PAD | 438 | #if CONFIG_KEYPAD == RECORDER_PAD |
439 | | BUTTON_F1 | BUTTON_F3 | 439 | | BUTTON_F1 | BUTTON_F3 |
440 | #endif | 440 | #endif |
441 | #if CONFIG_KEYPAD == SANSA_C200_PAD | ||
442 | | BUTTON_VOL_UP | BUTTON_VOL_DOWN | ||
443 | #endif | ||
441 | ); | 444 | ); |
442 | 445 | ||
443 | if (button & BUTTON_LEFT) | 446 | if (button & BUTTON_LEFT) |
@@ -462,6 +465,12 @@ static int button_flip(int button) | |||
462 | if (button & BUTTON_F3) | 465 | if (button & BUTTON_F3) |
463 | newbutton |= BUTTON_F1; | 466 | newbutton |= BUTTON_F1; |
464 | #endif | 467 | #endif |
468 | #if CONFIG_KEYPAD == SANSA_C200_PAD | ||
469 | if (button & BUTTON_VOL_UP) | ||
470 | newbutton |= BUTTON_VOL_DOWN; | ||
471 | if (button & BUTTON_VOL_DOWN) | ||
472 | newbutton |= BUTTON_VOL_UP; | ||
473 | #endif | ||
465 | 474 | ||
466 | return newbutton; | 475 | return newbutton; |
467 | } | 476 | } |