[Xfce4-commits] r25951 - xarchiver/trunk/src

Giuseppe Torelli colossus at xfce.org
Thu Aug 2 09:17:51 CEST 2007


Author: colossus
Date: 2007-08-02 07:17:51 +0000 (Thu, 02 Aug 2007)
New Revision: 25951

Modified:
   xarchiver/trunk/src/archive.c
   xarchiver/trunk/src/archive.h
   xarchiver/trunk/src/window.c
   xarchiver/trunk/src/zip.c
Log:
Fixed missing padlock icon when an entry in a directory is protected.


Modified: xarchiver/trunk/src/archive.c
===================================================================
--- xarchiver/trunk/src/archive.c	2007-08-02 06:44:04 UTC (rev 25950)
+++ xarchiver/trunk/src/archive.c	2007-08-02 07:17:51 UTC (rev 25951)
@@ -349,7 +349,7 @@
 	return found_entry;
 }
 
-XEntry *xa_set_archive_entries_for_each_row (XArchive *archive,gchar *filename,gpointer *items)
+XEntry *xa_set_archive_entries_for_each_row (XArchive *archive,gchar *filename,gboolean encrypted,gpointer *items)
 {
 	XEntry *child_entry= NULL;
 	XEntry *last_entry = NULL;
@@ -372,6 +372,7 @@
 			last_entry = xa_alloc_memory_for_each_row(archive->nc,archive->column_types);
 			last_entry->filename = g_strdup(full_path_name);
 			last_entry->columns = xa_fill_archive_entry_columns_for_each_row(archive,last_entry,items);
+			last_entry->is_dir = TRUE;
 			archive->entries = g_slist_prepend (archive->entries,last_entry);
 		}
 		p++;
@@ -401,8 +402,11 @@
 			filename_only = g_strndup(p,strlen(p));
 			child_entry = xa_alloc_memory_for_each_row (archive->nc,archive->column_types);
 			child_entry->filename = filename_only;
+			child_entry->columns = xa_fill_archive_entry_columns_for_each_row(archive,child_entry,items);
+			
+			if (encrypted)
+				child_entry->is_encrypted = TRUE;
 
-			child_entry->columns = xa_fill_archive_entry_columns_for_each_row(archive,child_entry,items);
 			child_entry->next = last_entry->child;
 			last_entry->child = child_entry;
 		}

Modified: xarchiver/trunk/src/archive.h
===================================================================
--- xarchiver/trunk/src/archive.h	2007-08-02 06:44:04 UTC (rev 25950)
+++ xarchiver/trunk/src/archive.h	2007-08-02 07:17:51 UTC (rev 25951)
@@ -125,7 +125,7 @@
 XEntry *xa_alloc_memory_for_each_row ( guint nc,GType column_types[]);
 void xa_free_entry (XArchive *archive,XEntry *entry);
 XEntry *xa_find_archive_entry(XEntry *entry, gchar *string);
-XEntry *xa_set_archive_entries_for_each_row (XArchive *archive,gchar *filename,gpointer *items);
+XEntry *xa_set_archive_entries_for_each_row (XArchive *archive,gchar *filename,gboolean encrypted,gpointer *items);
 gpointer *xa_fill_archive_entry_columns_for_each_row (XArchive *archive,XEntry *entry,gpointer *items);
 void xa_update_window_with_archive_entries (XArchive *archive,gchar *path);
 XArchive *archive[100];

Modified: xarchiver/trunk/src/window.c
===================================================================
--- xarchiver/trunk/src/window.c	2007-08-02 06:44:04 UTC (rev 25950)
+++ xarchiver/trunk/src/window.c	2007-08-02 07:17:51 UTC (rev 25951)
@@ -1166,7 +1166,7 @@
 	renderer = gtk_cell_renderer_pixbuf_new();
 	//GTK_ICON_SIZE_SMALL_TOOLBAR = 2;
 	//GTK_ICON_SIZE_LARGE_TOOLBAR = 3;
-	g_object_set(G_OBJECT(renderer), "stock-size", GTK_ICON_SIZE_SMALL_TOOLBAR, NULL);
+	g_object_set(G_OBJECT(renderer), "stock-size", GTK_ICON_SIZE_LARGE_TOOLBAR, NULL);
 	gtk_tree_view_column_pack_start(column, renderer, FALSE);
 	gtk_tree_view_column_set_attributes(column, renderer, "icon-name",0,NULL);
 

Modified: xarchiver/trunk/src/zip.c
===================================================================
--- xarchiver/trunk/src/zip.c	2007-08-02 06:44:04 UTC (rev 25950)
+++ xarchiver/trunk/src/zip.c	2007-08-02 07:17:51 UTC (rev 25951)
@@ -172,7 +172,7 @@
 	line[linesize-1] = '\0';
 	filename = line + n;
 
-	entry = xa_set_archive_entries_for_each_row (archive,filename,item);
+	entry = xa_set_archive_entries_for_each_row (archive,filename,encrypted,item);
 	if (entry != NULL)
 	{
 		if (dir)



More information about the Xfce4-commits mailing list