Author: gburt
Date: Sun Feb 17 04:02:56 2008
New Revision: 3258
URL: http://svn.gnome.org/viewvc/banshee?rev=3258&view=rev

Log:
2008-02-16  Gabriel Burt  <[EMAIL PROTECTED]>

        * src/Extensions/Banshee.Lastfm/Banshee.Lastfm.Radio/StationSource.cs:
        Only keep the last five played or skipped songs.


Modified:
   trunk/banshee/ChangeLog
   
trunk/banshee/src/Extensions/Banshee.Lastfm/Banshee.Lastfm.Radio/StationSource.cs

Modified: 
trunk/banshee/src/Extensions/Banshee.Lastfm/Banshee.Lastfm.Radio/StationSource.cs
==============================================================================
--- 
trunk/banshee/src/Extensions/Banshee.Lastfm/Banshee.Lastfm.Radio/StationSource.cs
   (original)
+++ 
trunk/banshee/src/Extensions/Banshee.Lastfm/Banshee.Lastfm.Radio/StationSource.cs
   Sun Feb 17 04:02:56 2008
@@ -370,6 +370,15 @@
                 CurrentTrack = ServiceManager.PlayerEngine.CurrentTrack;
 
                 lock (track_model) {
+                    // Remove up to the 5 most-recent tracks
+                    if (current_track > 5) {
+                        for (int i = 0; i < (current_track - 5); i++) {
+                            track_model.Remove (track_model[0]);
+                        }
+                        current_track = 5;
+                    }
+
+                    // Set all previous tracks as CanPlay = false
                     foreach (TrackInfo track in track_model) {
                         if (track == CurrentTrack)
                             break;
_______________________________________________
SVN-commits-list mailing list (read only)
http://mail.gnome.org/mailman/listinfo/svn-commits-list

Want to limit the commits to a few modules? Go to above URL, log in to edit 
your options and select the modules ('topics') you want.
Module maintainer? It is possible to set the reply-to to your development 
mailing list. Email [EMAIL PROTECTED] if interested.

Reply via email to