aboutsummaryrefslogtreecommitdiffstats
path: root/mail/message-list.c
diff options
context:
space:
mode:
authorDan Winship <danw@src.gnome.org>2001-05-11 00:16:06 +0800
committerDan Winship <danw@src.gnome.org>2001-05-11 00:16:06 +0800
commitdd04e750f24f2e0300bc45e4916dddf6d492024c (patch)
treeac6f49d91f1e4a00b0c3893bbbce742f82d1a550 /mail/message-list.c
parentc414a3739a0ff56590b093c64ff27122949c5ee3 (diff)
downloadgsoc2013-evolution-dd04e750f24f2e0300bc45e4916dddf6d492024c.tar
gsoc2013-evolution-dd04e750f24f2e0300bc45e4916dddf6d492024c.tar.gz
gsoc2013-evolution-dd04e750f24f2e0300bc45e4916dddf6d492024c.tar.bz2
gsoc2013-evolution-dd04e750f24f2e0300bc45e4916dddf6d492024c.tar.lz
gsoc2013-evolution-dd04e750f24f2e0300bc45e4916dddf6d492024c.tar.xz
gsoc2013-evolution-dd04e750f24f2e0300bc45e4916dddf6d492024c.tar.zst
gsoc2013-evolution-dd04e750f24f2e0300bc45e4916dddf6d492024c.zip
Don't advance to the next undeleted message after "Delete"...
* folder-browser.c (on_key_press): Don't advance to the next undeleted message after "Delete"... * mail-callbacks.c (delete_msg): ...instead, do it here, whether the user used Delete, Alt+D, or the toolbar. (But only if they only deleted a single message.) * message-list.c (message_list_select): Don't clear the display on failure. (build_tree): Clear the display when the currently-selected message stops existing and we don't have an obvious message to select instead of it. (Eg, when deleting the last message with "hide deleted messages" set, or expunging while a deleted message is selected.) svn path=/trunk/; revision=9744
Diffstat (limited to 'mail/message-list.c')
-rw-r--r--mail/message-list.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/mail/message-list.c b/mail/message-list.c
index 1c241efd1b..f42707e807 100644
--- a/mail/message-list.c
+++ b/mail/message-list.c
@@ -370,7 +370,7 @@ get_message_info (MessageList *message_list, ETreePath node)
* %MESSAGE_LIST_SELECT_NEXT if it should find the next matching
* message, or %MESSAGE_LIST_SELECT_PREVIOUS if it should find the
* previous. If no suitable row is found, the selection will be
- * unchanged but the message display will be cleared.
+ * unchanged.
**/
void
message_list_select (MessageList *message_list, int base_row,
@@ -417,11 +417,6 @@ message_list_select (MessageList *message_list, int base_row,
}
vrow += direction;
}
-
- g_free (message_list->cursor_uid);
- message_list->cursor_uid = NULL;
-
- gtk_signal_emit(GTK_OBJECT (message_list), message_list_signals [MESSAGE_SELECTED], NULL);
}
@@ -448,7 +443,7 @@ message_list_select_uid (MessageList *message_list, const char *uid)
} else {
g_free (message_list->cursor_uid);
message_list->cursor_uid = NULL;
- gtk_signal_emit (GTK_OBJECT (message_list), message_list_signals [MESSAGE_SELECTED], uid);
+ gtk_signal_emit (GTK_OBJECT (message_list), message_list_signals [MESSAGE_SELECTED], NULL);
}
}
@@ -1473,6 +1468,10 @@ build_tree (MessageList *ml, CamelFolderThread *thread, CamelFolderChangeInfo *c
e_tree_set_cursor(ml->tree, node);
}
g_free(saveuid);
+ } else if (ml->cursor_uid && !g_hash_table_lookup(ml->uid_nodemap, ml->cursor_uid)) {
+ g_free(ml->cursor_uid);
+ ml->cursor_uid = NULL;
+ gtk_signal_emit((GtkObject *)ml, message_list_signals[MESSAGE_SELECTED], NULL);
}
#ifdef TIMEIT