Bug 126594

Summary: When current playlist is empty, loading a random mix or playlist shuffle dynamic playlist should auto-populate.
Product: [Applications] amarok Reporter: Christie <dangle.baby>
Component: Playlists/Saved PlaylistsAssignee: Amarok Developers <amarok-bugs-dist>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:

Description Christie 2006-05-02 10:44:19 UTC
Version:           1.4-svn (using KDE KDE 3.5.2)
Installed from:    Compiled From Sources
Compiler:          gcc 4.0.3 
OS:                Linux

Recent changes to the way dynamic playlists load has introduced an extra (and not terribly intuitive) step.

When the current playlist is empty, and a "Random Mix" or a user defined "Playlist Shuffle" type dynamic playlist is loaded, the user must click the "Repopulate" button in order to populate the playlist the first time.

I can understand starting with a blank playlist for "Suggested Songs" - it's a different concept - but for the other two, the playlist really should be automatically populated if there are no tracks already in the playlist.
Comment 1 Seb Ruiz 2006-05-03 14:24:01 UTC
SVN commit 536912 by seb:

Automatically populate the playlist with items if it is empty when a dynamic playlist is loaded
BUG: 126594


 M  +2 -1      playlist.cpp  


--- trunk/extragear/multimedia/amarok/src/playlist.cpp #536911:536912
@@ -3156,6 +3156,8 @@
 {
     saveUndoState();
     setDynamicMode( mode );
+    if( isEmpty() )
+        repopulate();
 }
 
 void
@@ -3172,7 +3174,6 @@
 void
 Playlist::repopulate() //SLOT
 {
-    DEBUG_BLOCK
     // Repopulate the upcoming tracks
     MyIt it( this, MyIt::All );
     QPtrList<QListViewItem> list;