[beagle] Update tileIndex when removing a tile



commit 1f2e02c9f1e47b747d281510ab7bbd7950c568ee
Author: Vincent Untz <vuntz gnome org>
Date:   Fri Aug 14 13:31:59 2009 +0200

    Update tileIndex when removing a tile
    
    The bug was introduced with 7cfcb26c.
    
    http://bugzilla.gnome.org/show_bug.cgi?id=582354

 beagle/search/Beagle.Search/Category.cs |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/beagle/search/Beagle.Search/Category.cs b/beagle/search/Beagle.Search/Category.cs
index 06e8724..a008ef4 100644
--- a/beagle/search/Beagle.Search/Category.cs
+++ b/beagle/search/Beagle.Search/Category.cs
@@ -152,6 +152,8 @@ namespace Beagle.Search {
 
 			tiles.Remove ((Tiles.Tile)widget);
 
+			tileIndex = Math.Min( Math.Max( tiles.Count - 1, 0), tileIndex);
+
 			if (Expanded)
 				ShowTiles ();
 		}



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