Mercurial > pidgin.yaz
diff src/list.c @ 5170:13ffa9ae4282
[gaim-migrate @ 5534]
This makes the buddy ticker plugin work again, and may cause some slight
breakage in some plugins, since it slightly changes the behavior of:
event_buddy_signon
event_buddy_signoff
event_buddy_away
event_buddy_back
Then again, it's nothing compared to the massive breakage being thought up
for the very near future ;-)
committer: Tailor Script <tailor@pidgin.im>
author | Nathan Walp <nwalp@pidgin.im> |
---|---|
date | Fri, 18 Apr 2003 21:49:45 +0000 |
parents | 94f11800cac5 |
children | fefad67de2c7 |
line wrap: on
line diff
--- a/src/list.c Fri Apr 18 21:01:38 2003 +0000 +++ b/src/list.c Fri Apr 18 21:49:45 2003 +0000 @@ -118,6 +118,12 @@ { struct gaim_blist_ui_ops *ops = gaimbuddylist->ui_ops; buddy->uc = status; + + if(!(status & UC_UNAVAILABLE)) + plugin_event(event_buddy_back, buddy->account->gc, buddy->name); + else + plugin_event(event_buddy_away, buddy->account->gc, buddy->name); + if (ops) ops->update(gaimbuddylist, (GaimBlistNode*)buddy); } @@ -125,10 +131,12 @@ static gboolean presence_update_timeout_cb(struct buddy *buddy) { struct gaim_blist_ui_ops *ops = gaimbuddylist->ui_ops; - if(buddy->present == GAIM_BUDDY_SIGNING_ON) + if(buddy->present == GAIM_BUDDY_SIGNING_ON) { buddy->present = GAIM_BUDDY_ONLINE; - else if(buddy->present == GAIM_BUDDY_SIGNING_OFF) + plugin_event(event_buddy_signon, buddy->account->gc, buddy->name); + } else if(buddy->present == GAIM_BUDDY_SIGNING_OFF) { buddy->present = GAIM_BUDDY_OFFLINE; + } buddy->timer = 0; @@ -144,9 +152,11 @@ if (!GAIM_BUDDY_IS_ONLINE(buddy) && presence) { buddy->present = GAIM_BUDDY_SIGNING_ON; + plugin_event(event_buddy_signon, buddy->account->gc, buddy->name); do_timer = TRUE; } else if(GAIM_BUDDY_IS_ONLINE(buddy) && !presence) { buddy->present = GAIM_BUDDY_SIGNING_OFF; + plugin_event(event_buddy_signoff, buddy->account->gc, buddy->name); do_timer = TRUE; }