Changeset ec5e57d
- Timestamp:
- 2009-10-12T00:00:24Z (15 years ago)
- Branches:
- master
- Children:
- dd0d57b1
- Parents:
- b74b287
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
protocols/purple/purple.c
rb74b287 rec5e57d 174 174 static GList *purple_away_states( struct im_connection *ic ) 175 175 { 176 return NULL; 176 PurpleAccount *pa = ic->proto_data; 177 GList *st, *ret = NULL; 178 179 for( st = purple_account_get_status_types( pa ); st; st = st->next ) 180 { 181 printf( "%s\n", purple_status_type_get_name( st->data ) ); 182 ret = g_list_append( ret, (void*) purple_status_type_get_name( st->data ) ); 183 } 184 185 return ret; 177 186 } 178 187 179 188 static void purple_set_away( struct im_connection *ic, char *state_txt, char *message ) 180 189 { 190 PurpleAccount *pa = ic->proto_data; 191 GList *status_types = purple_account_get_status_types( pa ), *st; 192 PurpleStatusType *pst = NULL; 193 194 for( st = status_types; st; st = st->next ) 195 { 196 pst = st->data; 197 198 if( g_strcasecmp( state_txt, purple_status_type_get_name( pst ) ) == 0 ) 199 break; 200 } 201 202 purple_account_set_status( pa, st ? purple_status_type_get_id( pst ) : "away", 203 TRUE, "message", message, NULL ); 181 204 } 182 205 … … 355 378 NULL, /* custom_smiley_close */ 356 379 NULL, /* send_confirm */ 357 NULL,358 NULL,359 NULL,360 NULL361 380 }; 362 381
Note: See TracChangeset
for help on using the changeset viewer.