summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--firmware/mpeg.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/firmware/mpeg.c b/firmware/mpeg.c
index 7f736b4..2505b38 100644
--- a/firmware/mpeg.c
+++ b/firmware/mpeg.c
@@ -1343,9 +1343,10 @@ void mpeg_next(void)
#else
char* file;
int steps = 1;
+ int index;
do {
- file = playlist_next(steps, NULL);
+ file = playlist_next(steps, &index);
if(!file)
break;
if(mp3info(&taginfo, file)) {
@@ -1353,6 +1354,7 @@ void mpeg_next(void)
continue;
}
current_track_counter++;
+ taginfo.index = index;
playing = true;
break;
} while(1);
@@ -1366,9 +1368,10 @@ void mpeg_prev(void)
#else
char* file;
int steps = -1;
+ int index;
do {
- file = playlist_next(steps, NULL);
+ file = playlist_next(steps, &index);
if(!file)
break;
if(mp3info(&taginfo, file)) {
@@ -1376,6 +1379,7 @@ void mpeg_prev(void)
continue;
}
current_track_counter++;
+ taginfo.index = index;
playing = true;
break;
} while(1);