diff options
-rw-r--r-- | irc_im.c | 11 | ||||
-rw-r--r-- | protocols/bee.h | 1 | ||||
-rw-r--r-- | protocols/nogaim.c | 3 |
3 files changed, 15 insertions, 0 deletions
@@ -258,6 +258,16 @@ static gboolean bee_irc_user_fullname( bee_t *bee, bee_user_t *bu ) return TRUE; } +static gboolean bee_irc_user_group( bee_t *bee, bee_user_t *bu ) +{ + irc_user_t *iu = (irc_user_t *) bu->ui_data; + irc_t *irc = (irc_t *) bee->ui_data; + + bee_irc_channel_update( irc, NULL, iu ); + + return TRUE; +} + /* IRC->IM calls */ static gboolean bee_irc_user_privmsg( irc_user_t *iu, const char *msg ) @@ -543,6 +553,7 @@ const struct bee_ui_funcs irc_ui_funcs = { bee_irc_user_new, bee_irc_user_free, bee_irc_user_fullname, + bee_irc_user_group, bee_irc_user_status, bee_irc_user_msg, bee_irc_user_typing, diff --git a/protocols/bee.h b/protocols/bee.h index e421db57..5701ea60 100644 --- a/protocols/bee.h +++ b/protocols/bee.h @@ -82,6 +82,7 @@ typedef struct bee_ui_funcs gboolean (*user_new)( bee_t *bee, struct bee_user *bu ); gboolean (*user_free)( bee_t *bee, struct bee_user *bu ); gboolean (*user_fullname)( bee_t *bee, bee_user_t *bu ); + gboolean (*user_group)( bee_t *bee, bee_user_t *bu ); gboolean (*user_status)( bee_t *bee, struct bee_user *bu, struct bee_user *old ); gboolean (*user_msg)( bee_t *bee, bee_user_t *bu, const char *msg, time_t sent_at ); gboolean (*user_typing)( bee_t *bee, bee_user_t *bu, guint32 flags ); diff --git a/protocols/nogaim.c b/protocols/nogaim.c index 00fe0ebf..df97393d 100644 --- a/protocols/nogaim.c +++ b/protocols/nogaim.c @@ -378,6 +378,9 @@ void imcb_add_buddy( struct im_connection *ic, const char *handle, const char *g bu = bee_user_new( bee, ic, handle, 0 ); bu->group = bee_group_by_name( bee, group, TRUE ); + + if( bee->ui->user_group ) + bee->ui->user_group( bee, bu ); } void imcb_rename_buddy( struct im_connection *ic, const char *handle, const char *fullname ) |