--- ../../sylpheed-0.4.99/src/account.c Fri Jun 15 00:55:04 2001 +++ account.c Sat Jun 16 18:47:01 2001 @@ -676,3 +676,24 @@ row++) account_list = g_list_append(account_list, ac_prefs); } + +/* set to next account */ +void account_set_to_next(void) +{ + GList* cur; + PrefsAccount* ac_prefs; + + for (cur = account_list; cur != NULL; cur = cur->next) { + ac_prefs = (PrefsAccount*)cur->data; + if (!strcmp2(cur_account->account_name, ac_prefs->account_name)) { + if ((cur = cur->next) == NULL) + cur = account_list; + + if (cur != NULL) { + cur_account = (PrefsAccount*)cur->data; + account_set_menu(); + main_window_reflect_prefs_all(); + } + } + } +} --- ../../sylpheed-0.4.99/src/account.h Sun Mar 11 18:06:41 2001 +++ account.h Sat Jun 16 18:47:25 2001 @@ -47,5 +47,6 @@ PrefsAccount *account_get_default (void); void account_set_missing_folder(void); void account_destroy (PrefsAccount *ac_prefs); +void account_set_to_next (void); #endif /* __ACCOUNT_H__ */ --- ../../sylpheed-0.4.99/src/mainwindow.c Wed Jun 6 22:13:19 2001 +++ mainwindow.c Sat Jun 16 18:50:09 2001 @@ -328,6 +328,10 @@ FolderItem *item, gpointer data); +static void next_account_cb (MainWindow *mainwin, + guint action, + GtkWidget *widget); + static GtkItemFactoryEntry mainwin_entries[] = { {N_("/_File"), NULL, NULL, 0, ""}, @@ -517,6 +521,8 @@ NULL, account_edit_open, 0, NULL}, {N_("/_Configuration/C_hange current account"), NULL, NULL, 0, ""}, + {N_("/_Configuration/Change to next _account"), + "A", next_account_cb, 0, NULL}, {N_("/_Help"), NULL, NULL, 0, ""}, {N_("/_Help/_Manual"), NULL, NULL, 0, ""}, @@ -2092,4 +2098,10 @@ STATUSBAR_PUSH(mainwin, str); STATUSBAR_POP(mainwin); g_free(str); +} + +static void next_account_cb(MainWindow *mainwin, guint action, + GtkWidget *widget) +{ + account_set_to_next(); }