summaryrefslogtreecommitdiff
path: root/apps/menus
diff options
context:
space:
mode:
authorMichael Hohmuth <sideral@rockbox.org>2011-05-13 22:28:47 +0000
committerMichael Hohmuth <sideral@rockbox.org>2011-05-13 22:28:47 +0000
commit5aec3c2400fdd47c7b2098f1a1c5506a6aa3156c (patch)
tree875e48e0cf80f749a79d138b8787d84568171f70 /apps/menus
parent0a070c54202d946b37946343ea2f083fee82871a (diff)
downloadrockbox-5aec3c2400fdd47c7b2098f1a1c5506a6aa3156c.tar.gz
rockbox-5aec3c2400fdd47c7b2098f1a1c5506a6aa3156c.zip
FS#11931 part 2: Allow a short rewind when playback is paused. Patch
by John Morris. This patch adds an option to rewind the current track by a few seconds when it is paused, irrespective of what has caused the pause. This is useful for audiobooks and podcasts to allow the listener to recall where the track was left off. The patch subsumes the existing rewind-on-headphone-unplug feature and extends it to all invocations of pause: play/pause button (or touch area), headphone removal, and power-supply unplug in car-adapter mode. It also subsumes FS#9448 (rewind on fade). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29876 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/menus')
-rw-r--r--apps/menus/playback_menu.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/apps/menus/playback_menu.c b/apps/menus/playback_menu.c
index 4153c1c776..1b1a13a6a5 100644
--- a/apps/menus/playback_menu.c
+++ b/apps/menus/playback_menu.c
@@ -173,10 +173,9 @@ MENUITEM_SETTING(cuesheet, &global_settings.cuesheet, cuesheet_callback);
173 173
174#ifdef HAVE_HEADPHONE_DETECTION 174#ifdef HAVE_HEADPHONE_DETECTION
175MENUITEM_SETTING(unplug_mode, &global_settings.unplug_mode, NULL); 175MENUITEM_SETTING(unplug_mode, &global_settings.unplug_mode, NULL);
176MENUITEM_SETTING(unplug_rw, &global_settings.unplug_rw, NULL);
177MENUITEM_SETTING(unplug_autoresume, &global_settings.unplug_autoresume, NULL); 176MENUITEM_SETTING(unplug_autoresume, &global_settings.unplug_autoresume, NULL);
178MAKE_MENU(unplug_menu, ID2P(LANG_HEADPHONE_UNPLUG), 0, Icon_NOICON, 177MAKE_MENU(unplug_menu, ID2P(LANG_HEADPHONE_UNPLUG), 0, Icon_NOICON,
179 &unplug_mode, &unplug_rw, &unplug_autoresume); 178 &unplug_mode, &unplug_autoresume);
180#endif 179#endif
181 180
182MENUITEM_SETTING(skip_length, &global_settings.skip_length, NULL); 181MENUITEM_SETTING(skip_length, &global_settings.skip_length, NULL);
@@ -184,6 +183,7 @@ MENUITEM_SETTING(prevent_skip, &global_settings.prevent_skip, NULL);
184#if CONFIG_CODEC == SWCODEC 183#if CONFIG_CODEC == SWCODEC
185MENUITEM_SETTING(resume_rewind, &global_settings.resume_rewind, NULL); 184MENUITEM_SETTING(resume_rewind, &global_settings.resume_rewind, NULL);
186#endif 185#endif
186MENUITEM_SETTING(pause_rewind, &global_settings.pause_rewind, NULL);
187 187
188MAKE_MENU(playback_settings,ID2P(LANG_PLAYBACK),0, 188MAKE_MENU(playback_settings,ID2P(LANG_PLAYBACK),0,
189 Icon_Playback_menu, 189 Icon_Playback_menu,
@@ -214,6 +214,7 @@ MAKE_MENU(playback_settings,ID2P(LANG_PLAYBACK),0,
214#if CONFIG_CODEC == SWCODEC 214#if CONFIG_CODEC == SWCODEC
215 &resume_rewind, 215 &resume_rewind,
216#endif 216#endif
217 &pause_rewind,
217 ); 218 );
218 219
219static int playback_callback(int action,const struct menu_item_ex *this_item) 220static int playback_callback(int action,const struct menu_item_ex *this_item)