Mercurial > pidgin
diff src/account.c @ 7067:71e0da45abe6
[gaim-migrate @ 7631]
Core/UI split show_set_info().
committer: Tailor Script <tailor@pidgin.im>
author | Christian Hammond <chipx86@chipx86.com> |
---|---|
date | Tue, 30 Sep 2003 08:08:34 +0000 |
parents | 7fdac700deb1 |
children | 9220c7490cd1 |
line wrap: on
line diff
--- a/src/account.c Tue Sep 30 07:57:03 2003 +0000 +++ b/src/account.c Tue Sep 30 08:08:34 2003 +0000 @@ -277,7 +277,6 @@ serv_change_passwd(gaim_account_get_connection(account), orig_pass, new_pass_1); gaim_account_set_password(account, new_pass_1); - } void @@ -327,6 +326,39 @@ account); } +static void +set_user_info_cb(GaimAccount *account, const char *user_info) +{ + GaimConnection *gc; + + gaim_account_set_user_info(account, user_info); + + gc = gaim_account_get_connection(account); + + if (gc != NULL) + serv_set_info(gaim_account_get_connection(account), user_info); +} + +void +gaim_account_request_change_user_info(GaimAccount *account) +{ + char primary[256]; + + g_return_if_fail(account != NULL); + g_return_if_fail(gaim_account_is_connected(account)); + + g_snprintf(primary, sizeof(primary), + _("Change user information for %s"), + gaim_account_get_username(account)); + + gaim_request_input(gaim_account_get_connection(account), + NULL, primary, NULL, + gaim_account_get_user_info(account), + TRUE, FALSE, + _("Save"), G_CALLBACK(set_user_info_cb), + _("Cancel"), NULL, account); +} + void gaim_account_set_username(GaimAccount *account, const char *username) {