comparison src/buddy.c @ 3136:1bd472b7f7a2

[gaim-migrate @ 3151] Jabber sync. fixen committer: Tailor Script <tailor@pidgin.im>
author Rob Flynn <gaim@robflynn.com>
date Fri, 12 Apr 2002 02:15:24 +0000
parents 1838f48a5f72
children b7fce1bf6b87
comparison
equal deleted inserted replaced
3135:1838f48a5f72 3136:1bd472b7f7a2
752 struct group_show *gs = find_group_show(g->name); 752 struct group_show *gs = find_group_show(g->name);
753 struct buddy_show *bs = NULL; 753 struct buddy_show *bs = NULL;
754 GtkCTreeNode *node = gtk_ctree_find_by_row_data(GTK_CTREE(edittree), NULL, b); 754 GtkCTreeNode *node = gtk_ctree_find_by_row_data(GTK_CTREE(edittree), NULL, b);
755 g_snprintf(b->show, sizeof(b->show), "%s", b->name); 755 g_snprintf(b->show, sizeof(b->show), "%s", b->name);
756 gtk_ctree_node_set_text(GTK_CTREE(edittree), node, 0, b->name); 756 gtk_ctree_node_set_text(GTK_CTREE(edittree), node, 0, b->name);
757 serv_alias_buddy(b);
757 if (gs) 758 if (gs)
758 bs = find_buddy_show(gs, b->name); 759 bs = find_buddy_show(gs, b->name);
759 if (bs) 760 if (bs)
760 gtk_label_set(GTK_LABEL(bs->label), b->name); 761 gtk_label_set(GTK_LABEL(bs->label), b->name);
761 do_export(b->gc); 762 do_export(b->gc);
1092 else 1093 else
1093 new_g->members = g_slist_prepend(new_g->members, buddy); 1094 new_g->members = g_slist_prepend(new_g->members, buddy);
1094 } else 1095 } else
1095 new_g->members = g_slist_append(new_g->members, buddy); 1096 new_g->members = g_slist_append(new_g->members, buddy);
1096 1097
1097 /* we do the add after it's added locally so that prpls can find it if necessary */ 1098 /*
1098 if (add) 1099 * we do the add after it's added locally so that prpls can find it if necessary
1100 * JFIXME: Er, shouldn't the buddy be removed from the old server, as well?
1101 */
1102 if (add) {
1099 serv_add_buddy(new_g->gc, buddy->name); 1103 serv_add_buddy(new_g->gc, buddy->name);
1104 } else {
1105 serv_move_buddy(buddy, old_g, new_g);
1106 }
1100 1107
1101 do_export(buddy->gc); 1108 do_export(buddy->gc);
1102 if (buddy->gc != new_g->gc) { 1109 if (buddy->gc != new_g->gc) {
1103 do_export(new_g->gc); 1110 do_export(new_g->gc);
1104 build_edit_tree(); 1111 build_edit_tree();