fix bug of selection of last inserted tree node, not necessarily the last displayed...
authorAlfons Hoogervorst <alfons@proteus.demon.nl>
Sat, 6 Oct 2001 10:39:17 +0000 (10:39 +0000)
committerAlfons Hoogervorst <alfons@proteus.demon.nl>
Sat, 6 Oct 2001 10:39:17 +0000 (10:39 +0000)
ChangeLog.claws
configure.in
src/summaryview.c

index 00bdf512ca16151f041e459e41e4582fca079669..39685033179f5803aae32816bef4fe0a930013a2 100644 (file)
@@ -1,3 +1,10 @@
+2001-10-06 [alfons]    0.6.2.claws22
+
+       * src/summaryview.c
+               fix bug with summary view selecting last *inserted*
+               node instead of last *visible* node. remember we
+               work with a tree
+
 2001-10-06 [paul]      0.6.2claws21
 
        * po/pt_BR.po
index 04181cd683060a9a4d089fdbd6af0a2fef443657..12a876df52274d649fff12f82c20984ddccd9223 100644 (file)
@@ -8,7 +8,7 @@ MINOR_VERSION=6
 MICRO_VERSION=2
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=claws21
+EXTRA_VERSION=claws22
 VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION
 
 dnl
index 18501a178ab8559e529a38178e2bdeb178c5e3e9..ba8ad611b5f59ac479b27b46f1a1f657f9b06c25 100644 (file)
@@ -922,8 +922,11 @@ gboolean summary_show(SummaryView *summaryview, FolderItem *item,
                else
                        node = summary_find_next_unread_msg(summaryview, NULL);
 
-               if (node == NULL && GTK_CLIST(ctree)->row_list != NULL)
-                       node = GTK_CTREE_NODE(GTK_CLIST(ctree)->row_list_end);
+               if (node == NULL && GTK_CLIST(ctree)->row_list != NULL) {
+                       /* Get the last visible node on screen */
+                       /* FIXME: huh, what happens if node is null? that allowed?? */
+                       node = gtk_ctree_node_nth(ctree, GTK_CLIST(ctree)->rows - 1);
+               }       
                if (prefs_common.open_unread_on_enter) {
                        summary_unlock(summaryview);
                        summary_select_node(summaryview, node, TRUE);