diff options
author | Brandon Low <lostlogic@rockbox.org> | 2006-01-25 16:53:32 +0000 |
---|---|---|
committer | Brandon Low <lostlogic@rockbox.org> | 2006-01-25 16:53:32 +0000 |
commit | 4781f1461fd7d3f91bea4ff84ca20b5e58ff53e3 (patch) | |
tree | 9afdac66b8e87f51f594f155a0a977de41ae793f /apps | |
parent | 60e8f4f9885d3cffb6cb7aa3b0e09a3fed0d3c84 (diff) |
Functional AB on iRiver H1x0, and improved button mappings (share the NEXTDIR and PREVDIR buttons on iRiver H[13]x0 targets), patch from IRC:lamed, modified by me.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8450 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
-rw-r--r-- | apps/gui/gwps.c | 22 | ||||
-rw-r--r-- | apps/gui/gwps.h | 5 |
2 files changed, 22 insertions, 5 deletions
diff --git a/apps/gui/gwps.c b/apps/gui/gwps.c index f75dd80d0f..d7d436c089 100644 --- a/apps/gui/gwps.c +++ b/apps/gui/gwps.c @@ -426,7 +426,18 @@ long gui_wps_show(void) case WPS_RC_NEXT_DIR: #endif case WPS_NEXT_DIR: - audio_next_dir(); +#if defined(AB_REPEAT_ENABLE) && defined(WPS_AB_SHARE_DIR_BUTTONS) + if (ab_repeat_mode_enabled()) + { + ab_set_B_marker(wps_state.id3->elapsed); + ab_jump_to_A_marker(); + update_track = true; + } + else +#endif + { + audio_next_dir(); + } break; #endif #ifdef WPS_PREV_DIR @@ -434,7 +445,14 @@ long gui_wps_show(void) case WPS_RC_PREV_DIR: #endif case WPS_PREV_DIR: - audio_prev_dir(); +#if defined(AB_REPEAT_ENABLE) && defined(WPS_AB_SHARE_DIR_BUTTONS) + if (ab_repeat_mode_enabled()) + ab_set_A_marker(wps_state.id3->elapsed); + else +#endif + { + audio_prev_dir(); + } break; #endif diff --git a/apps/gui/gwps.h b/apps/gui/gwps.h index 59c5019e39..eb976c9220 100644 --- a/apps/gui/gwps.h +++ b/apps/gui/gwps.h @@ -69,9 +69,8 @@ #define WPS_RC_QUICK (BUTTON_RC_MODE | BUTTON_REPEAT) #ifdef AB_REPEAT_ENABLE -#define WPS_AB_SET_A_MARKER (BUTTON_REC | BUTTON_LEFT) -#define WPS_AB_SET_B_MARKER (BUTTON_REC | BUTTON_RIGHT) -#define WPS_AB_RESET_AB_MARKERS (BUTTON_REC | BUTTON_OFF) +#define WPS_AB_SHARE_DIR_BUTTONS +#define WPS_AB_RESET_AB_MARKERS (BUTTON_ON | BUTTON_SELECT) #endif #elif CONFIG_KEYPAD == RECORDER_PAD |