From 8b6146945853c38723b3e80ce08fc1bd78a34189 Mon Sep 17 00:00:00 2001 From: Wilmer van der Gaast Date: Fri, 30 Jul 2010 15:28:22 +0100 Subject: Don't notify the UI about group changes if there wasn't, in fact, a change. This should stop the odd left+joins that were happening sometimes. --- protocols/nogaim.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'protocols') diff --git a/protocols/nogaim.c b/protocols/nogaim.c index d8c7d05a..c14b222d 100644 --- a/protocols/nogaim.c +++ b/protocols/nogaim.c @@ -381,13 +381,15 @@ void imcb_add_buddy( struct im_connection *ic, const char *handle, const char *g { bee_user_t *bu; bee_t *bee = ic->bee; + bee_group_t *oldg; if( !( bu = bee_user_by_handle( bee, ic, handle ) ) ) bu = bee_user_new( bee, ic, handle, 0 ); + oldg = bu->group; bu->group = bee_group_by_name( bee, group, TRUE ); - if( bee->ui->user_group ) + if( bee->ui->user_group && bu->group != oldg ) bee->ui->user_group( bee, bu ); } -- cgit v1.2.3