#10 Load random songs only when shuffle play mode is enabled

open
nobody
None
5
2012-09-06
2012-01-22
Timo
No

This patch fixes issue 3466455 (https://sourceforge.net/tracker/?func=detail&aid=3466455&group_id=126265&atid=705132).

Instead of starting to fill the random buffer right on start, filling is now dependent on whether shuffle play mode is enabled or not. If shuffle play mode is enabled, the background service in ShufflePlayBuffer is started. As soon as the playlist is cleaned, the service is stopped.

Caveat: After applying the patch it takes a while for shuffle play mode to commence. While this is OK by itself, there is no notification for the user to indicate that random songs are being retrieved over the network. Instead, the download tab shows an empty queue for a short while until song retrieval concludes (which causes the queue to fill and download to start in an instance). This is somewhat bad from a UX point of view as the initial user impression is that no progress is being made.

IMHO, the long-term fix is to show a "connecting server..." message similar to when the music library is browsed. Unfortunately, I wasn't perfectly sure how to implement this correctly -- my impression is that one needs to pass a ProgressListener somehow down to ShufflePlayBuffer. When the desired approach is determined, this add-on feature can be provided in a subsequent patch.

Discussion

  • Timo
    Timo
    2012-01-22

    The patch was tested against revision 2701.

     


Anonymous


Cancel   Add attachments