fix problem where no mail is selected after moving the last one
authorColin Leroy <colin@colino.net>
Sat, 12 Oct 2002 11:13:08 +0000 (11:13 +0000)
committerColin Leroy <colin@colino.net>
Sat, 12 Oct 2002 11:13:08 +0000 (11:13 +0000)
ChangeLog.claws
configure.in
src/summaryview.c

index df45e0e6f14b4883ecbb25644844174928415ca5..cc642e983e4aebe1df37bb278c4a0dfdbe346065 100644 (file)
@@ -1,3 +1,9 @@
+2002-10-12 [colin]     0.8.5claws24
+
+       * src/summaryview.c
+               Fix the problem consisting of no message selected
+               after the last message in a folder has been moved.
+
 2002-10-12 [paul]      0.8.5claws23
 
        * src/compose.c
index 9e0b36d9e8e84b913f534c1edd1ffb991760aff7..59a3a13863a50bf4ca9728ca62af87c6fbca93ce 100644 (file)
@@ -11,7 +11,7 @@ MINOR_VERSION=8
 MICRO_VERSION=5
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=claws23
+EXTRA_VERSION=claws24
 VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION
 
 dnl set $target
index ec7281bf2ed3dd34ba18de505d9fd564fa557b19..562f3c84f55d4cc0f8d97bf1ad9efc889fe58ea6 100644 (file)
@@ -3128,6 +3128,14 @@ void summary_move_selected_to(SummaryView *summaryview, FolderItem *to_folder)
 
                folderview_update_item(to_folder, 0);
        }
+       
+       if (!summaryview->selected) { /* this was the last message */
+               GtkCTreeNode *node = gtk_ctree_node_nth (GTK_CTREE(summaryview->ctree), 
+                                                        GTK_CLIST(summaryview->ctree)->rows - 1);
+               if (node)
+                       summary_select_node(summaryview, node, TRUE, TRUE);
+       }
+
 }
 
 void summary_move_to(SummaryView *summaryview)