changeset 827:e5172386f229

Revert patches 759 and 760. 759 patch broke adding selection of files through sort manager to an unopened collection.
author zas_
date Fri, 13 Jun 2008 12:27:41 +0000
parents daebdd1f5bc6
children 08a78e3e06f9
files src/collect-io.c src/thumb_standard.c
diffstat 2 files changed, 20 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/src/collect-io.c	Fri Jun 13 11:51:23 2008 +0000
+++ b/src/collect-io.c	Fri Jun 13 12:27:41 2008 +0000
@@ -860,10 +860,16 @@
 
 	/* we keep track of the list's tail to keep this a n(1) operation */
 
-	collection_manager_action_tail = g_list_append(collection_manager_action_tail, action);
-	if (!collection_manager_action_list) 
-		collection_manager_action_list = collection_manager_action_tail;
-	collection_manager_action_tail = collection_manager_action_tail->next;
+	if (collection_manager_action_tail)
+		{
+		collection_manager_action_tail = g_list_append(collection_manager_action_tail, action);
+		collection_manager_action_tail = collection_manager_action_tail->next;
+		}
+	else
+		{
+		collection_manager_action_list = g_list_append(collection_manager_action_list, action);
+		collection_manager_action_tail = collection_manager_action_list;
+		}
 
 	collect_manager_timer_push(FALSE);
 }
--- a/src/thumb_standard.c	Fri Jun 13 11:51:23 2008 +0000
+++ b/src/thumb_standard.c	Fri Jun 13 12:27:41 2008 +0000
@@ -1065,8 +1065,14 @@
 		g_idle_add_full(G_PRIORITY_LOW, thumb_std_maint_move_idle, NULL, NULL);
 		}
 
-	thumb_std_maint_move_tail = g_list_append(thumb_std_maint_move_tail, tm);
-	if (!thumb_std_maint_move_list)
-		thumb_std_maint_move_list = thumb_std_maint_move_tail;
-	thumb_std_maint_move_tail = thumb_std_maint_move_tail->next;
+	if (thumb_std_maint_move_tail)
+		{
+		thumb_std_maint_move_tail = g_list_append(thumb_std_maint_move_tail, tm);
+		thumb_std_maint_move_tail = thumb_std_maint_move_tail->next;
+		}
+	else
+		{
+		thumb_std_maint_move_list = g_list_append(thumb_std_maint_move_list, tm);
+		thumb_std_maint_move_tail = thumb_std_maint_move_list;
+		}
 }