diff options
author | phintuka <phintuka> | 2010-12-19 14:25:38 +0000 |
---|---|---|
committer | phintuka <phintuka> | 2010-12-19 14:25:38 +0000 |
commit | 87056b8658e45197c5646daacf8c6045ab0bc016 (patch) | |
tree | f2e35a603b5af0c98ef26623bd147bdf6edc2e4f | |
parent | 953c6053e77a216414d8fee1c556872f423d1f4e (diff) | |
download | xineliboutput-87056b8658e45197c5646daacf8c6045ab0bc016.tar.gz xineliboutput-87056b8658e45197c5646daacf8c6045ab0bc016.tar.bz2 |
Fixed cPlaylist::Seek() forward seeking (was off by one)
-rw-r--r-- | tools/playlist.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/tools/playlist.c b/tools/playlist.c index c517bd46..e65a03c0 100644 --- a/tools/playlist.c +++ b/tools/playlist.c @@ -4,7 +4,7 @@ * See the main source file 'xineliboutput.c' for copyright information and * how to reach the author. * - * $Id: playlist.c,v 1.32 2010-12-09 14:13:03 phintuka Exp $ + * $Id: playlist.c,v 1.33 2010-12-19 14:25:38 phintuka Exp $ * */ @@ -530,13 +530,14 @@ cPlaylistItem *cPlaylist::Seek(int Rel) if (!Current()) return NULL; - if (Rel > 0) + if (Rel > 0) { while (Rel--) m_Current = (cList<cPlaylistItem>::Next(Current()) ?: Last()); - if (Rel < 0) + } else if (Rel < 0) { while (Rel++) m_Current = (cList<cPlaylistItem>::Prev(Current()) ?: First()); + } return Current(); } |