aboutsummaryrefslogtreecommitdiffstats
path: root/protocols/yahoo/yahoo.c
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2006-03-01 23:48:37 +0100
committerJelmer Vernooij <jelmer@samba.org>2006-03-01 23:48:37 +0100
commita4dc9f77de03eb46ecabed02dbd1b678319cf11d (patch)
tree71a8dfa927ea2ac4bfc30a36b4d9324a51247aeb /protocols/yahoo/yahoo.c
parent8e419cb4f86679636b2d96618e1bec4853636c11 (diff)
parent9a1555dc8521f0973347911bcb26d1038259f967 (diff)
[merge] Wilmer
Diffstat (limited to 'protocols/yahoo/yahoo.c')
-rw-r--r--protocols/yahoo/yahoo.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/protocols/yahoo/yahoo.c b/protocols/yahoo/yahoo.c
index 832d1ab4..4f257d99 100644
--- a/protocols/yahoo/yahoo.c
+++ b/protocols/yahoo/yahoo.c
@@ -188,18 +188,18 @@ static int byahoo_send_typing( struct gaim_connection *gc, char *who, int typing
static void byahoo_set_away( struct gaim_connection *gc, char *state, char *msg )
{
struct byahoo_data *yd = (struct byahoo_data *) gc->proto_data;
-
+
gc->away = NULL;
-
- if (msg)
+
+ if( msg )
{
yd->current_status = YAHOO_STATUS_CUSTOM;
gc->away = "";
}
- else if (state)
+ if( state )
{
gc->away = "";
- if( g_strcasecmp(state, "Available" ) == 0 )
+ if( g_strcasecmp( state, "Available" ) == 0 )
{
yd->current_status = YAHOO_STATUS_AVAILABLE;
gc->away = NULL;
@@ -234,12 +234,15 @@ static void byahoo_set_away( struct gaim_connection *gc, char *state, char *msg
gc->away = NULL;
}
}
- else if ( gc->is_idle )
+ else if( gc->is_idle )
yd->current_status = YAHOO_STATUS_IDLE;
else
yd->current_status = YAHOO_STATUS_AVAILABLE;
- yahoo_set_away( yd->y2_id, yd->current_status, msg, gc->away != NULL );
+ if( yd->current_status == YAHOO_STATUS_INVISIBLE )
+ yahoo_set_away( yd->y2_id, yd->current_status, NULL, gc->away != NULL );
+ else
+ yahoo_set_away( yd->y2_id, yd->current_status, msg, gc->away != NULL );
}
static GList *byahoo_away_states( struct gaim_connection *gc )