Mercurial > pidgin.yaz
comparison src/blist.c @ 5313:8d118c2b03c9
[gaim-migrate @ 5685]
fix online accounts when dragging buddies around
committer: Tailor Script <tailor@pidgin.im>
author | Nathan Walp <nwalp@pidgin.im> |
---|---|
date | Tue, 06 May 2003 05:28:41 +0000 |
parents | d2732160850b |
children | c1e7c3f72128 |
comparison
equal
deleted
inserted
replaced
5312:89948fedf782 | 5313:8d118c2b03c9 |
---|---|
412 * being moved. | 412 * being moved. |
413 */ | 413 */ |
414 ((struct group *)bnode->parent)->totalsize--; | 414 ((struct group *)bnode->parent)->totalsize--; |
415 if (buddy->account->gc) | 415 if (buddy->account->gc) |
416 ((struct group *)bnode->parent)->currentsize--; | 416 ((struct group *)bnode->parent)->currentsize--; |
417 if (buddy->present) | |
418 ((struct group *)bnode->parent)->online--; | |
417 | 419 |
418 if(bnode->next) | 420 if(bnode->next) |
419 bnode->next->prev = bnode->prev; | 421 bnode->next->prev = bnode->prev; |
420 if(bnode->prev) | 422 if(bnode->prev) |
421 bnode->prev->next = bnode->next; | 423 bnode->prev->next = bnode->next; |
438 ((GaimBlistNode*)buddy)->parent = n->parent; | 440 ((GaimBlistNode*)buddy)->parent = n->parent; |
439 n->next = (GaimBlistNode*)buddy; | 441 n->next = (GaimBlistNode*)buddy; |
440 ((struct group *)n->parent)->totalsize++; | 442 ((struct group *)n->parent)->totalsize++; |
441 if (buddy->account->gc) | 443 if (buddy->account->gc) |
442 ((struct group *)n->parent)->currentsize++; | 444 ((struct group *)n->parent)->currentsize++; |
445 if (buddy->present) | |
446 ((struct group *)n->parent)->online++; | |
443 } else { | 447 } else { |
444 ((GaimBlistNode*)g)->child = (GaimBlistNode*)buddy; | 448 ((GaimBlistNode*)g)->child = (GaimBlistNode*)buddy; |
445 ((GaimBlistNode*)buddy)->next = NULL; | 449 ((GaimBlistNode*)buddy)->next = NULL; |
446 ((GaimBlistNode*)buddy)->prev = NULL; | 450 ((GaimBlistNode*)buddy)->prev = NULL; |
447 ((GaimBlistNode*)buddy)->parent = (GaimBlistNode*)g; | 451 ((GaimBlistNode*)buddy)->parent = (GaimBlistNode*)g; |
448 g->totalsize++; | 452 g->totalsize++; |
449 if (buddy->account->gc) | 453 if (buddy->account->gc) |
450 g->currentsize++; | 454 g->currentsize++; |
455 if (buddy->present) | |
456 g->online++; | |
451 } | 457 } |
452 | 458 |
453 hb = g_malloc(sizeof(struct _gaim_hbuddy)); | 459 hb = g_malloc(sizeof(struct _gaim_hbuddy)); |
454 hb->name = g_strdup(normalize(buddy->name)); | 460 hb->name = g_strdup(normalize(buddy->name)); |
455 hb->account = buddy->account; | 461 hb->account = buddy->account; |