summaryrefslogtreecommitdiff
path: root/apps/menus/playback_menu.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/menus/playback_menu.c')
-rw-r--r--apps/menus/playback_menu.c39
1 files changed, 0 insertions, 39 deletions
diff --git a/apps/menus/playback_menu.c b/apps/menus/playback_menu.c
index e4945be0b5..a0732d3feb 100644
--- a/apps/menus/playback_menu.c
+++ b/apps/menus/playback_menu.c
@@ -244,19 +244,9 @@ static int playback_callback(int action,
244 struct gui_synclist *this_list) 244 struct gui_synclist *this_list)
245{ 245{
246 (void)this_list; 246 (void)this_list;
247 static bool old_shuffle = false;
248 static int old_repeat = 0;
249 switch (action) 247 switch (action)
250 { 248 {
251 case ACTION_ENTER_MENUITEM: 249 case ACTION_ENTER_MENUITEM:
252 if (this_item == &shuffle_item)
253 {
254 old_shuffle = global_settings.playlist_shuffle;
255 }
256 else if (this_item == &repeat_mode)
257 {
258 old_repeat = global_settings.repeat_mode;
259 }
260 break; 250 break;
261 251
262 case ACTION_EXIT_MENUITEM: /* on exit */ 252 case ACTION_EXIT_MENUITEM: /* on exit */
@@ -268,35 +258,6 @@ static int playback_callback(int action,
268 break; 258 break;
269 } 259 }
270#endif /* HAVE_PLAY_FREQ */ 260#endif /* HAVE_PLAY_FREQ */
271
272 if (!(audio_status() & AUDIO_STATUS_PLAY))
273 break;
274
275 /* Playing only */
276 if (this_item == &shuffle_item)
277 {
278 if (old_shuffle == global_settings.playlist_shuffle)
279 break;
280
281 replaygain_update();
282
283 if (global_settings.playlist_shuffle)
284 {
285 playlist_randomise(NULL, current_tick, true);
286 }
287 else
288 {
289 playlist_sort(NULL, true);
290 }
291 }
292 else if (this_item == &repeat_mode)
293 {
294 if (old_repeat == global_settings.repeat_mode)
295 break;
296
297 audio_flush_and_reload_tracks();
298 }
299
300 break; 261 break;
301 } 262 }
302 return action; 263 return action;