banshee r3881 - in trunk/banshee: . src/Core/Banshee.ThickClient/Banshee.Collection.Gui



Author: gburt
Date: Mon May  5 19:05:26 2008
New Revision: 3881
URL: http://svn.gnome.org/viewvc/banshee?rev=3881&view=rev

Log:
2008-05-05  Gabriel Burt  <gabriel burt gmail com>

	* src/Core/Banshee.ThickClient/Banshee.Collection.Gui/ColumnCellPlaybackIndicator.cs:
	Be more defensive with checking for null/cast errors.


Modified:
   trunk/banshee/ChangeLog
   trunk/banshee/src/Core/Banshee.ThickClient/Banshee.Collection.Gui/ColumnCellPlaybackIndicator.cs

Modified: trunk/banshee/src/Core/Banshee.ThickClient/Banshee.Collection.Gui/ColumnCellPlaybackIndicator.cs
==============================================================================
--- trunk/banshee/src/Core/Banshee.ThickClient/Banshee.Collection.Gui/ColumnCellPlaybackIndicator.cs	(original)
+++ trunk/banshee/src/Core/Banshee.ThickClient/Banshee.Collection.Gui/ColumnCellPlaybackIndicator.cs	Mon May  5 19:05:26 2008
@@ -79,7 +79,10 @@
 
         public override void Render (CellContext context, StateType state, double cellWidth, double cellHeight)
         {
-            TrackInfo track = (TrackInfo)BoundObject;
+            TrackInfo track = BoundObject as TrackInfo;
+
+            if (track == null)
+                return;
         
             if (track.PlaybackError == StreamPlaybackError.None && !ServiceManager.PlayerEngine.IsPlaying (track)) {
                 return;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]