From 591b98e2192bb7f36ad1b5638acd2c225e13aac3 Mon Sep 17 00:00:00 2001 From: Not Zed Date: Mon, 17 May 2004 06:10:53 +0000 Subject: put the None item at the head of the providers list. 2004-05-17 Not Zed * mail-account-gui.c (mail_account_gui_setup): put the None item at the head of the providers list. (mail_account_gui_setup): only set the transport default fallback if it is not a STORE_AND_TRANSPORT type provider (since that was just disabled). #57939. * message-list.c (on_selection_changed_cmd): only NOOP if we have no selection and no uid, if we have a selection and no uid, then always update. Fixes #58267 without breaking the double-load thing. svn path=/trunk/; revision=25919 --- mail/ChangeLog | 11 +++++++++++ mail/mail-account-gui.c | 27 ++++++++++++++------------- mail/message-list.c | 5 ++++- 3 files changed, 29 insertions(+), 14 deletions(-) diff --git a/mail/ChangeLog b/mail/ChangeLog index 247c66f1d4..f6e6716366 100644 --- a/mail/ChangeLog +++ b/mail/ChangeLog @@ -1,5 +1,16 @@ 2004-05-17 Not Zed + * mail-account-gui.c (mail_account_gui_setup): put the None item + at the head of the providers list. + (mail_account_gui_setup): only set the transport default fallback + if it is not a STORE_AND_TRANSPORT type provider (since that was + just disabled). #57939. + + * message-list.c (on_selection_changed_cmd): only NOOP if we have + no selection and no uid, if we have a selection and no uid, then + always update. Fixes #58267 without breaking the double-load + thing. + * em-folder-view.c (em_folder_view_open_selected): keep the hide deleted status. Makes #51082 work at last. diff --git a/mail/mail-account-gui.c b/mail/mail-account-gui.c index fb0b2d14cc..f5a3d25ddc 100644 --- a/mail/mail-account-gui.c +++ b/mail/mail-account-gui.c @@ -1924,7 +1924,7 @@ mail_account_gui_new (EAccount *account, EMAccountPrefs *dialog) void mail_account_gui_setup (MailAccountGui *gui, GtkWidget *top) { - GtkWidget *stores, *transports, *item; + GtkWidget *stores, *transports, *item, *none; GtkWidget *fstore = NULL, *ftransport = NULL; int si = 0, hstore = 0, ti = 0, htransport = 0; int max_width = 0; @@ -1950,6 +1950,15 @@ mail_account_gui_setup (MailAccountGui *gui, GtkWidget *top) /* Construct source/transport option menus */ stores = gtk_menu_new (); transports = gtk_menu_new (); + + /* add a "None" option to the stores menu */ + none = item = gtk_menu_item_new_with_label (_("None")); + g_object_set_data ((GObject *) item, "provider", NULL); + g_signal_connect (item, "activate", G_CALLBACK (source_type_changed), gui); + gtk_menu_shell_append(GTK_MENU_SHELL(stores), item); + gtk_widget_show (item); + si++; + providers = camel_provider_list(TRUE); /* sort the providers, remote first */ @@ -2000,7 +2009,8 @@ mail_account_gui_setup (MailAccountGui *gui, GtkWidget *top) if (CAMEL_PROVIDER_IS_STORE_AND_TRANSPORT (provider)) gtk_widget_set_sensitive (item, FALSE); - if (!ftransport) { + if (!ftransport + && !CAMEL_PROVIDER_IS_STORE_AND_TRANSPORT (provider)) { ftransport = item; htransport = ti; } @@ -2035,18 +2045,9 @@ mail_account_gui_setup (MailAccountGui *gui, GtkWidget *top) } g_list_free (providers); - /* add a "None" option to the stores menu */ - item = gtk_menu_item_new_with_label (_("None")); - g_object_set_data ((GObject *) item, "provider", NULL); - g_signal_connect (item, "activate", G_CALLBACK (source_type_changed), gui); - - gtk_menu_shell_append(GTK_MENU_SHELL(stores), item); - - gtk_widget_show (item); - if (!fstore || !source_proto) { - fstore = item; - hstore = si; + fstore = none; + hstore = 0; } /* set the menus on the optionmenus */ diff --git a/mail/message-list.c b/mail/message-list.c index 0fd105c14e..f488c8bf1a 100644 --- a/mail/message-list.c +++ b/mail/message-list.c @@ -2844,7 +2844,10 @@ on_selection_changed_cmd(ETree *tree, MessageList *ml) else newuid = NULL; - if ((newuid == NULL && ml->cursor_uid == NULL) + /* If the selection isn't empty, then we ignore the no-uid check, since this event + is also used for other updating. If it is empty, it might just be a setup event + from etree which we do need to ignore */ + if ((newuid == NULL && ml->cursor_uid == NULL && uids->len == 0) || (newuid != NULL && ml->cursor_uid != NULL && !strcmp(ml->cursor_uid, newuid))) { /* noop */ } else { -- cgit v1.2.3