From ea9e02b4428e0fb5e69f17511d809f74dbd3b273 Mon Sep 17 00:00:00 2001 From: Nicolas Pennequin Date: Tue, 26 Feb 2008 17:15:30 +0000 Subject: [PATCH] Make audio_next_track use the wps_offset value. This removes the delay between the current track title change and the next track title change in the WPS on a track skip. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16423 a1c6a512-1295-4272-9138-f99709370657 --- apps/playback.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/apps/playback.c b/apps/playback.c index cca5b73247..0f0f70e6fd 100644 --- a/apps/playback.c +++ b/apps/playback.c @@ -553,7 +553,8 @@ struct mp3entry* audio_current_track(void) struct mp3entry* audio_next_track(void) { - int next_idx = track_ridx; + int next_idx; + int offset = ci.new_track + wps_offset; if (!audio_have_tracks()) return NULL; @@ -565,7 +566,7 @@ struct mp3entry* audio_next_track(void) return &curtrack_id3; } - next_idx = (next_idx + 1) & MAX_TRACK_MASK; + next_idx = (track_ridx + offset + 1) & MAX_TRACK_MASK; if (next_idx == track_widx) {