Mercurial > pidgin
diff src/account.c @ 10714:ad57a8b5495e
[gaim-migrate @ 12308]
Some minor status changes.
* Using the "enable?" checkbox in the account window will now sign on
an account if it was offline. I'm starting to get a feel for how
some of this stuff should work...
* Signing on an account that doesn't support available messages no
longer shows some warnings.
committer: Tailor Script <tailor@pidgin.im>
author | Mark Doliner <mark@kingant.net> |
---|---|
date | Mon, 21 Mar 2005 05:22:09 +0000 |
parents | 6a618db0a404 |
children | 0e017707532f |
line wrap: on
line diff
--- a/src/account.c Mon Mar 21 04:17:21 2005 +0000 +++ b/src/account.c Mon Mar 21 05:22:09 2005 +0000 @@ -991,6 +991,7 @@ gboolean active, ...) { GaimStatus *status; + GaimStatusType *status_type; va_list args; g_return_if_fail(account != NULL); @@ -1010,6 +1011,17 @@ va_start(args, active); gaim_status_set_active_with_attrs(status, active, args); va_end(args); + + /* + * If this account should be connected, but is not, then connect. + */ + status_type = gaim_status_get_type(status); + if (active && + (gaim_status_type_get_primitive(status_type) != GAIM_STATUS_OFFLINE) && + !gaim_account_is_connected(account)) + { + gaim_account_connect(account, status); + } } void