Mercurial > pidgin.yaz
comparison src/protocols/oscar/oscar.c @ 11002:bf03a5271395
[gaim-migrate @ 12857]
Fix moving all buddies from one group to another. KingAnt can you look at the XXX note that I added
committer: Tailor Script <tailor@pidgin.im>
author | Daniel Atallah <daniel.atallah@gmail.com> |
---|---|
date | Sat, 11 Jun 2005 22:30:08 +0000 |
parents | 1adca5a37fb8 |
children | bb7fd9359f9e |
comparison
equal
deleted
inserted
replaced
11001:0c9e936c154b | 11002:bf03a5271395 |
---|---|
5911 GList *cur, *groups = NULL; | 5911 GList *cur, *groups = NULL; |
5912 | 5912 |
5913 /* Make a list of what the groups each buddy is in */ | 5913 /* Make a list of what the groups each buddy is in */ |
5914 for (cur = moved_buddies; cur != NULL; cur = cur->next) { | 5914 for (cur = moved_buddies; cur != NULL; cur = cur->next) { |
5915 GaimBlistNode *node = cur->data; | 5915 GaimBlistNode *node = cur->data; |
5916 groups = g_list_append(groups, node->parent); | 5916 /* node is GaimBuddy, parent is a GaimContact. |
5917 * We must go two levels up to get the Group */ | |
5918 groups = g_list_append(groups, | |
5919 node->parent->parent); | |
5917 } | 5920 } |
5918 | 5921 |
5919 serv_remove_buddies(gc, moved_buddies, groups); | 5922 serv_remove_buddies(gc, moved_buddies, groups); |
5920 serv_add_buddies(gc, moved_buddies); | 5923 serv_add_buddies(gc, moved_buddies); |
5921 g_list_free(groups); | 5924 g_list_free(groups); |
5925 /** XXX: Shouldn't be we deleting the old group on the server here??? */ | |
5922 gaim_debug_info("oscar", | 5926 gaim_debug_info("oscar", |
5923 "ssi: moved all buddies from group %s to %s\n", old_name, group->name); | 5927 "ssi: moved all buddies from group %s to %s\n", old_name, group->name); |
5924 } else { | 5928 } else { |
5925 aim_ssi_rename_group(od->sess, old_name, group->name); | 5929 aim_ssi_rename_group(od->sess, old_name, group->name); |
5926 gaim_debug_info("oscar", | 5930 gaim_debug_info("oscar", |