Mercurial > pidgin.yaz
changeset 7382:e6e194f9d44c
[gaim-migrate @ 7977]
i don't know if this makes trepia work (i don't really care) but it does let it compile
committer: Tailor Script <tailor@pidgin.im>
author | Nathan Walp <nwalp@pidgin.im> |
---|---|
date | Thu, 30 Oct 2003 16:02:28 +0000 |
parents | 75733c68479a |
children | f1fe68ef00c7 |
files | src/protocols/trepia/profile.h src/protocols/trepia/trepia.c |
diffstat | 2 files changed, 32 insertions(+), 22 deletions(-) [+] |
line wrap: on
line diff
--- a/src/protocols/trepia/profile.h Thu Oct 30 15:39:01 2003 +0000 +++ b/src/protocols/trepia/profile.h Thu Oct 30 16:02:28 2003 +0000 @@ -28,7 +28,7 @@ typedef struct { - struct buddy *buddy; + GaimBuddy *buddy; int type; /* c */
--- a/src/protocols/trepia/trepia.c Thu Oct 30 15:39:01 2003 +0000 +++ b/src/protocols/trepia/trepia.c Thu Oct 30 16:02:28 2003 +0000 @@ -125,17 +125,26 @@ static void __clear_user_list(TrepiaSession *session) { - GaimBlistNode *gnode, *bnode; + GaimBlistNode *gnode, *cnode, *bnode; for(gnode = gaim_get_blist()->root; gnode; gnode = gnode->next) { - bnode = gnode->child; - while(bnode) { - struct buddy *buddy = (struct buddy *)bnode; - if(GAIM_BLIST_NODE_IS_BUDDY(bnode) && - buddy->account == session->gc->account) { - bnode = bnode->next; - gaim_blist_remove_buddy(buddy); + cnode = gnode->child; + + while(cnode) { + if(GAIM_BLIST_NODE_IS_CONTACT(cnode)) { + bnode = cnode->child; + cnode = cnode->next; + while(bnode) { + GaimBuddy *buddy = (GaimBuddy *)bnode; + if(GAIM_BLIST_NODE_IS_BUDDY(bnode) && + buddy->account == session->gc->account) { + bnode = bnode->next; + gaim_blist_remove_buddy(buddy); + } else { + bnode = bnode->next; + } + } } else { - bnode = bnode->next; + cnode = cnode->next; } } } @@ -343,13 +352,13 @@ **************************************************************************/ static const char * -trepia_list_icon(GaimAccount *a, struct buddy *b) +trepia_list_icon(GaimAccount *a, GaimBuddy *b) { return "trepia"; } static void -trepia_list_emblems(struct buddy *b, char **se, char **sw, +trepia_list_emblems(GaimBuddy *b, char **se, char **sw, char **nw, char **ne) { TrepiaProfile *profile = (TrepiaProfile *)b->proto_data; @@ -361,7 +370,7 @@ } static char * -trepia_status_text(struct buddy *b) +trepia_status_text(GaimBuddy *b) { TrepiaProfile *profile = (TrepiaProfile *)b->proto_data; const char *value; @@ -374,7 +383,7 @@ } static char * -trepia_tooltip_text(struct buddy *b) +trepia_tooltip_text(GaimBuddy *b) { TrepiaProfile *profile = (TrepiaProfile *)b->proto_data; const char *value; @@ -490,7 +499,7 @@ trepia_visit_homepage(GaimConnection *gc, const char *who) { TrepiaProfile *profile; - struct buddy *b; + GaimBuddy *b; const char *value; b = gaim_find_buddy(gaim_connection_get_account(gc), who); @@ -504,7 +513,7 @@ trepia_buddy_menu(GaimConnection *gc, const char *who) { TrepiaProfile *profile; - struct buddy *b; + GaimBuddy *b; const char *value = NULL; GList *m = NULL; struct proto_buddy_menu *pbm; @@ -656,7 +665,7 @@ TrepiaProfile *profile = NULL; int ret; char *buffer; - struct buddy *b; + GaimBuddy *b; int id = 0; const char *value; char *username; @@ -858,7 +867,7 @@ b = gaim_find_buddy(account, username); if (b == NULL) { - struct group *g; + GaimGroup *g; g = gaim_find_group(_("Local Users")); @@ -869,7 +878,7 @@ b = gaim_buddy_new(account, username, NULL); - gaim_blist_add_buddy(b, g, NULL); + gaim_blist_add_buddy(b, NULL, g, NULL); } profile->buddy = b; @@ -894,7 +903,8 @@ gaim_base64_decode(value, &icon, &icon_len); - set_icon_data(session->gc, username, icon, icon_len); + gaim_buddy_icons_set_for_user(session->gc->account, + username, icon, icon_len); g_free(icon); @@ -1137,7 +1147,7 @@ { TrepiaSession *session = gc->proto_data; TrepiaProfile *profile; - struct buddy *b; + GaimBuddy *b; char *escaped_msg; char *buffer; @@ -1182,7 +1192,7 @@ } static void -trepia_buddy_free(struct buddy *b) +trepia_buddy_free(GaimBuddy *b) { if (b->proto_data != NULL) { trepia_profile_destroy(b->proto_data);