Mercurial > pidgin.yaz
comparison libpurple/protocols/irc/msgs.c @ 25284:985ab911753e
updated irc to use the api rather than structs directly
author | Gary Kramlich <grim@reaperworld.com> |
---|---|
date | Fri, 31 Oct 2008 03:42:38 +0000 |
parents | e6b79961f69b |
children | da46097b4722 |
comparison
equal
deleted
inserted
replaced
25283:4d20fa86455b | 25284:985ab911753e |
---|---|
93 PurplePluginProtocolInfo *prpl_info = PURPLE_PLUGIN_PROTOCOL_INFO(gc->prpl); | 93 PurplePluginProtocolInfo *prpl_info = PURPLE_PLUGIN_PROTOCOL_INFO(gc->prpl); |
94 prpl_info->set_status(irc->account, status); | 94 prpl_info->set_status(irc->account, status); |
95 } | 95 } |
96 | 96 |
97 /* this used to be in the core, but it's not now */ | 97 /* this used to be in the core, but it's not now */ |
98 for (gnode = purple_get_blist()->root; gnode; gnode = gnode->next) { | 98 for (gnode = purple_blist_get_root(); |
99 gnode; | |
100 gnode = purple_blist_node_get_sibling_next(gnode)) | |
101 { | |
99 if(!PURPLE_BLIST_NODE_IS_GROUP(gnode)) | 102 if(!PURPLE_BLIST_NODE_IS_GROUP(gnode)) |
100 continue; | 103 continue; |
101 for(cnode = gnode->child; cnode; cnode = cnode->next) { | 104 for(cnode = purple_blist_node_get_first_child(gnode); |
105 cnode; | |
106 cnode = purple_blist_node_get_sibling_next(cnode)) | |
107 { | |
102 if(!PURPLE_BLIST_NODE_IS_CONTACT(cnode)) | 108 if(!PURPLE_BLIST_NODE_IS_CONTACT(cnode)) |
103 continue; | 109 continue; |
104 for(bnode = cnode->child; bnode; bnode = bnode->next) { | 110 for(bnode = purple_blist_node_get_first_child(cnode); |
111 bnode; | |
112 bnode = purple_blist_node_get_sibling_next(bnode)) | |
113 { | |
105 PurpleBuddy *b; | 114 PurpleBuddy *b; |
106 if(!PURPLE_BLIST_NODE_IS_BUDDY(bnode)) | 115 if(!PURPLE_BLIST_NODE_IS_BUDDY(bnode)) |
107 continue; | 116 continue; |
108 b = (PurpleBuddy *)bnode; | 117 b = (PurpleBuddy *)bnode; |
109 if(b->account == gc->account) { | 118 if(purple_buddy_get_account(b) == gc->account) { |
110 struct irc_buddy *ib = g_new0(struct irc_buddy, 1); | 119 struct irc_buddy *ib = g_new0(struct irc_buddy, 1); |
111 ib->name = g_strdup(b->name); | 120 ib->name = g_strdup(purple_buddy_get_name(b)); |
112 g_hash_table_insert(irc->buddies, ib->name, ib); | 121 g_hash_table_insert(irc->buddies, ib->name, ib); |
113 } | 122 } |
114 } | 123 } |
115 } | 124 } |
116 } | 125 } |