Mercurial > pidgin
diff src/account.c @ 9019:db1dc2d02020
[gaim-migrate @ 9795]
Fiddled with a few small things
1) Added a GAIM_CONNECTION_IS_CONNECTED(gc) #define to connection.h
2) In the functions that build the Account Actions and Plugin Actions
menus, I didn't think the comment "plugin and gc will be set from
the counting loop already" was accurate (but it might be, becase
it seemed like the account actions menu worked with one account
online). So I made sure plugin and gc are set to what they should
be.
3) Changed gaim_account_is_connected() to use GAIM_CONNECTION_IS_CONNECTED
Previously gaim_account_is_connected() would return true for gc's
that were "GAIM_CONNECTING." Now it only returns true for gc's that
are "GAIM_CONNECTED."
committer: Tailor Script <tailor@pidgin.im>
author | Mark Doliner <mark@kingant.net> |
---|---|
date | Sat, 22 May 2004 23:08:27 +0000 |
parents | beb7be215db3 |
children | 3d30ed8dc7b0 |
line wrap: on
line diff
--- a/src/account.c Sat May 22 22:37:33 2004 +0000 +++ b/src/account.c Sat May 22 23:08:27 2004 +0000 @@ -677,10 +677,13 @@ gboolean gaim_account_is_connected(const GaimAccount *account) { + GaimConnection *gc; + g_return_val_if_fail(account != NULL, FALSE); - return (account->gc != NULL && - gaim_connection_get_state(account->gc) != GAIM_DISCONNECTED); + gc = gaim_account_get_connection(account); + + return ((gc != NULL) && GAIM_CONNECTION_IS_CONNECTED(gc)); } const char *