librespot/src
Nick Steel b9b8e110df Improved next/prev handling for queued tracks.
1) A queued track is removed once it has become the current track.
   Note that the track doesn't need to actually play i.e. it could
   have been immediately skipped over with 'next()'. This is
   implemented in 'consume_queue()'.

2) Queued tracks are always positioned immediately after the current
   track. 1) ensures this is true for 'next()' but 'prev()' requires
   all the queued tracks are actually moved for this to remain the
   case.

Also fixed the case where 'prev()' on the first track would incorrectly
wrap back around to the last track even when repeat was disabled. The
correct behaviour is to remain on the first track and just seek to the
start.

For example, with the following tracks and repeat enabled:

TrackA, TrackB, TrackC-Q, TrackD-Q, TrackE
        ^^^^^^

Here, the result of 'prev' changes the current track from TrackB to
TrackA and the queued tracks (TrackC, TrackD) move to the position
immediately after TrackA:

TrackA, TrackC-Q, TrackD-Q, TrackB, TrackE
^^^^^^

Calling 'prev' again results in the current track wrapping back around
to TrackE and the queued tracks moving after that same track:

TrackA, TrackB, TrackE, TrackC-Q, TrackD-Q
                ^^^^^^
2018-02-06 22:54:22 +00:00
..
audio_backend Merge branch 'master' into jackaudio 2018-02-02 05:12:36 +01:00
mixer Allow switching user accounts at runtime 2017-02-22 04:18:27 +00:00
discovery.rs simplify dns-sd/mdns code 2018-02-02 19:53:08 +01:00
keymaster.rs Remove usage of deprecated BoxFuture, BoxStream and BoxSink 2018-01-25 23:23:45 +01:00
lib.in.rs Disable the "variable does not need to be mutable" compiler warning in generated code 2017-12-17 23:15:49 +01:00
lib.rs Merge branch 'master' into jackaudio 2018-02-02 05:12:36 +01:00
main.rs Merge pull request #110 from librespot-org/inital-volume-ifelse-cleanup 2018-01-30 23:38:36 +00:00
player.rs Use futures::sync::oneshot::Sender::send() instead of the deprecated complete() 2018-01-25 23:23:45 +01:00
spirc.rs Improved next/prev handling for queued tracks. 2018-02-06 22:54:22 +00:00