gedit r6394 - in trunk: . plugins/filebrowser



Author: pborelli
Date: Wed Aug 13 14:01:14 2008
New Revision: 6394
URL: http://svn.gnome.org/viewvc/gedit?rev=6394&view=rev

Log:
2008-08-13  Paolo Borelli  <pborelli katamail com>

        * plugins/filebrowser/gedit-file-browser-store.c: do not print a
        warning on sart when the saved root was deleted



Modified:
   trunk/ChangeLog
   trunk/plugins/filebrowser/gedit-file-browser-store.c

Modified: trunk/plugins/filebrowser/gedit-file-browser-store.c
==============================================================================
--- trunk/plugins/filebrowser/gedit-file-browser-store.c	(original)
+++ trunk/plugins/filebrowser/gedit-file-browser-store.c	Wed Aug 13 14:01:14 2008
@@ -1797,12 +1797,13 @@
 					  &error);
 					  
 		if (!info) {
-			uri = g_file_get_uri (node->file);
-			
-			g_warning ("Could not get info for %s: %s", uri, error->message);
+			if (!(error->domain == G_IO_ERROR && error->code == G_IO_ERROR_NOT_FOUND)) {
+				uri = g_file_get_uri (node->file);
+				g_warning ("Could not get info for %s: %s", uri, error->message);
+				g_free (uri);
+			}
 			g_error_free (error);
-			g_free (uri);
-			
+
 			return;
 		}
 		
@@ -1914,20 +1915,19 @@
 static FileBrowserNode *
 model_add_node_from_dir (GeditFileBrowserStore * model,
 			 FileBrowserNode * parent,
-			 GFile * file,
-			 GFileInfo * info)
+			 GFile * file)
 {
 	FileBrowserNode *node;
 
-	// Check if it already exists
+	/* Check if it already exists */
 	if ((node = model_file_exists (model, parent, file)) == NULL) {	
 		node = file_browser_node_dir_new (model, file, parent);
-		file_browser_node_set_from_info (model, node, info, FALSE);
+		file_browser_node_set_from_info (model, node, NULL, FALSE);
 
 		if (node->name == NULL) {
 			file_browser_node_set_name (node);
 		}
-		
+
 		if (node->icon == NULL) {
 			node->icon = gedit_file_browser_utils_pixbuf_from_theme ("folder", GTK_ICON_SIZE_MENU);
 		}
@@ -2403,7 +2403,7 @@
 	for (item = files; item; item = item->next) {
 		check = G_FILE (item->data);
 		
-		parent = model_add_node_from_dir (model, parent, check, NULL);
+		parent = model_add_node_from_dir (model, parent, check);
 		g_object_unref (check);
 	}
 



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