nemo r120 - trunk/gtk



Author: arj
Date: Wed Aug  6 14:19:27 2008
New Revision: 120
URL: http://svn.gnome.org/viewvc/nemo?rev=120&view=rev

Log:
Fix a crash with two labels selected

Patch from Laszlo Pandy <laszlok2 gmail com>



Modified:
   trunk/gtk/MainWindow.cs

Modified: trunk/gtk/MainWindow.cs
==============================================================================
--- trunk/gtk/MainWindow.cs	(original)
+++ trunk/gtk/MainWindow.cs	Wed Aug  6 14:19:27 2008
@@ -252,13 +252,17 @@
 
 		foreach (File file in search_results) 
 		{
+			string path = "file://" + file.path;
+			
+			if (callbacks.ContainsKey(path)) {
+				continue;
+			}
+			
 			ItemWrapper wrapper = new ItemWrapper(new Nemo.Item(file));
 			
 			files.Add(file.path);
 			
-			string path = file.path;
-			
-			callbacks.Add("file://" + path, Helpers.RunInMainThread<string[]>(delegate(string[] result) {
+			callbacks.Add(path, Helpers.RunInMainThread<string[]>(delegate(string[] result) {
 				
 //				System.Console.WriteLine("results: {0}", result.Length);
 				System.Console.WriteLine("result: {0} for {1}", result[0], path);



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