diff options
author | Wilmer van der Gaast <wilmer@gaast.net> | 2010-06-07 16:11:09 +0100 |
---|---|---|
committer | Wilmer van der Gaast <wilmer@gaast.net> | 2010-06-07 16:11:09 +0100 |
commit | 56699f009a608ecff3a247a08b3d0105a5e17153 (patch) | |
tree | 9884c0b47ed1f7d062c0567c8505cc120deb4a26 /protocols/bee_user.c | |
parent | 4aa0f6bc5645e124738ab15ad1eb65d4147dba25 (diff) |
Show idle + login time info in /WHOIS (if available).
Diffstat (limited to 'protocols/bee_user.c')
-rw-r--r-- | protocols/bee_user.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/protocols/bee_user.c b/protocols/bee_user.c index fd2e8635..28235a6d 100644 --- a/protocols/bee_user.c +++ b/protocols/bee_user.c @@ -191,6 +191,18 @@ void imcb_buddy_status( struct im_connection *ic, const char *handle, int flags, g_free( old ); } +void imcb_buddy_times( struct im_connection *ic, const char *handle, time_t login, time_t idle ) +{ + bee_t *bee = ic->bee; + bee_user_t *bu; + + if( !( bu = bee_user_by_handle( bee, ic, handle ) ) ) + return; + + bu->login_time = login; + bu->idle_time = idle; +} + void imcb_buddy_msg( struct im_connection *ic, const char *handle, char *msg, uint32_t flags, time_t sent_at ) { bee_t *bee = ic->bee; |