[Xfce4-commits] r24337 - in squeeze/trunk: libsqueeze src

Stephan Arts stephan at xfce.org
Tue Jan 9 23:34:28 CET 2007


Author: stephan
Date: 2007-01-09 22:34:28 +0000 (Tue, 09 Jan 2007)
New Revision: 24337

Modified:
   squeeze/trunk/libsqueeze/archive-support-gnu-tar.c
   squeeze/trunk/libsqueeze/archive-support-zip.c
   squeeze/trunk/src/archive_store.c
   squeeze/trunk/src/properties_dialog.c
   squeeze/trunk/src/properties_dialog.h
Log:
- Fixed property-update for zip and gnu-tar in libsqueeze
- Changed property-dialog
- Removed wrong debugging output and assert from archive-store



Modified: squeeze/trunk/libsqueeze/archive-support-gnu-tar.c
===================================================================
--- squeeze/trunk/libsqueeze/archive-support-gnu-tar.c	2007-01-09 18:03:53 UTC (rev 24336)
+++ squeeze/trunk/libsqueeze/archive-support-gnu-tar.c	2007-01-09 22:34:28 UTC (rev 24337)
@@ -471,6 +471,7 @@
 	}
 	else
 	{
+		lsq_archive_clear_entry_property_types(archive);
 		i = LSQ_ARCHIVE_PROP_USER;
 		if(LSQ_ARCHIVE_SUPPORT_GNU_TAR(archive->support)->_view_rights) {
 			lsq_archive_set_entry_property_type(archive, i, G_TYPE_STRING, _("Permissions"));

Modified: squeeze/trunk/libsqueeze/archive-support-zip.c
===================================================================
--- squeeze/trunk/libsqueeze/archive-support-zip.c	2007-01-09 18:03:53 UTC (rev 24336)
+++ squeeze/trunk/libsqueeze/archive-support-zip.c	2007-01-09 22:34:28 UTC (rev 24337)
@@ -309,6 +309,7 @@
 	}
 	else
 	{
+		lsq_archive_clear_entry_property_types(archive);
 		i = LSQ_ARCHIVE_PROP_USER;
 		if(LSQ_ARCHIVE_SUPPORT_ZIP(archive->support)->_view_length) {
 			lsq_archive_set_entry_property_type(archive, i, G_TYPE_UINT64, _("Size"));

Modified: squeeze/trunk/src/archive_store.c
===================================================================
--- squeeze/trunk/src/archive_store.c	2007-01-09 18:03:53 UTC (rev 24336)
+++ squeeze/trunk/src/archive_store.c	2007-01-09 22:34:28 UTC (rev 24337)
@@ -454,8 +454,12 @@
 			entry = lsq_archive_iter_nth_child(archive, entry, index);
 
 		if(!entry)
+		{
+#ifdef DEBUG
 			g_debug("iter %d not found", index);
-		g_return_val_if_fail(entry, FALSE);
+#endif
+			return FALSE;
+		}
 	}
 
 	iter->stamp = store->stamp;

Modified: squeeze/trunk/src/properties_dialog.c
===================================================================
--- squeeze/trunk/src/properties_dialog.c	2007-01-09 18:03:53 UTC (rev 24336)
+++ squeeze/trunk/src/properties_dialog.c	2007-01-09 22:34:28 UTC (rev 24337)
@@ -88,9 +88,10 @@
 	gtk_box_pack_start (GTK_BOX (box), label, FALSE, TRUE, 0);
 	gtk_widget_show (label);
 
+	dialog->filename_label = gtk_label_new("");
+	gtk_table_attach (dialog->table, dialog->filename_label, 1, 2, 0, 1, GTK_FILL, GTK_FILL, 0, 3);
+	gtk_widget_show(dialog->filename_label);
 
-
-
 	gtk_dialog_add_buttons(GTK_DIALOG(dialog),
 	    GTK_STOCK_CLOSE, GTK_RESPONSE_OK,
 			NULL);
@@ -110,5 +111,7 @@
 	GdkPixbuf *icon = gtk_icon_theme_load_icon(icon_theme, thunar_vfs_mime_info_lookup_icon_name(archive->mime_info, icon_theme), 48, 0, NULL);
 	gtk_image_set_from_pixbuf(GTK_IMAGE(((SQPropertiesDialog *)dialog)->icon_image), icon);
 
+	gtk_label_set_text(GTK_LABEL(((SQPropertiesDialog *)dialog)->filename_label), lsq_archive_get_filename(archive));
+
 	return dialog;
 }

Modified: squeeze/trunk/src/properties_dialog.h
===================================================================
--- squeeze/trunk/src/properties_dialog.h	2007-01-09 18:03:53 UTC (rev 24336)
+++ squeeze/trunk/src/properties_dialog.h	2007-01-09 22:34:28 UTC (rev 24337)
@@ -50,6 +50,7 @@
 	GtkDialog parent;
 	GtkTable  *table;
 	GtkWidget *icon_image;
+	GtkWidget *filename_label;
 };
 
 typedef struct _SQPropertiesDialogClass SQPropertiesDialogClass;



More information about the Xfce4-commits mailing list