aboutsummaryrefslogtreecommitdiffstats
path: root/mail/mail-accounts.c
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@helixcode.com>2001-01-09 14:20:18 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2001-01-09 14:20:18 +0800
commitdc5ef3b9a4c72a24d09f4612f6822298808703f8 (patch)
tree37e2c7ebcd676b148e5e37cf1962d613a6cc543f /mail/mail-accounts.c
parenta2d998fe1391733fa472f2c142891d31fd81f958 (diff)
downloadgsoc2013-evolution-dc5ef3b9a4c72a24d09f4612f6822298808703f8.tar.gz
gsoc2013-evolution-dc5ef3b9a4c72a24d09f4612f6822298808703f8.tar.zst
gsoc2013-evolution-dc5ef3b9a4c72a24d09f4612f6822298808703f8.zip
Write the config data and reload the accounts list so the "default" tag is
2001-01-09 Jeffrey Stedfast <fejj@helixcode.com> * mail-accounts.c (mail_default): Write the config data and reload the accounts list so the "default" tag is relocated. (mail_delete): Write the config data here too. svn path=/trunk/; revision=7314
Diffstat (limited to 'mail/mail-accounts.c')
-rw-r--r--mail/mail-accounts.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/mail/mail-accounts.c b/mail/mail-accounts.c
index 6d6d9b9fce..9d0fd7090c 100644
--- a/mail/mail-accounts.c
+++ b/mail/mail-accounts.c
@@ -212,8 +212,10 @@ mail_delete (GtkButton *button, gpointer data)
int row, len;
account = gtk_clist_get_row_data (dialog->mail_accounts, dialog->accounts_row);
- g_list_remove ((GList *)dialog->accounts, account);
+ g_slist_remove ((GSList *) dialog->accounts, account);
account_destroy (account);
+ mail_config_write ();
+
gtk_clist_remove (dialog->mail_accounts, dialog->accounts_row);
len = g_slist_length ((GSList *) dialog->accounts);
@@ -239,6 +241,8 @@ mail_default (GtkButton *button, gpointer data)
if (dialog->accounts_row >= 0) {
account = gtk_clist_get_row_data (dialog->mail_accounts, dialog->accounts_row);
mail_config_set_default_account (account);
+ mail_config_write ();
+ load_accounts (dialog);
}
}
@@ -296,8 +300,10 @@ news_delete (GtkButton *button, gpointer data)
int row, len;
server = gtk_clist_get_row_data (dialog->news_accounts, dialog->news_row);
- g_list_remove ((GList *)dialog->news, server);
+ g_slist_remove ((GSList *) dialog->news, server);
service_destroy (server);
+ mail_config_write ();
+
gtk_clist_remove (dialog->news_accounts, dialog->news_row);
len = g_slist_length ((GSList *) dialog->news);