From 4f4c33a6cab809bae137b9141e0c1697f951e9ec Mon Sep 17 00:00:00 2001 From: Danielle Madeley Date: Mon, 13 Jun 2011 17:00:06 +0100 Subject: [PATCH] Only decrement unread_messages if it's not an edited message Prevents ending up with message counts of -1 --- libempathy-gtk/empathy-chat.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/libempathy-gtk/empathy-chat.c b/libempathy-gtk/empathy-chat.c index 5cee9eb0..ecf849aa 100644 --- a/libempathy-gtk/empathy-chat.c +++ b/libempathy-gtk/empathy-chat.c @@ -1384,8 +1384,10 @@ chat_message_acknowledged_cb (EmpathyTpChat *tp_chat, empathy_chat_view_message_acknowledged (chat->view, message); - priv->unread_messages--; - g_object_notify (G_OBJECT (chat), "nb-unread-messages"); + if (!empathy_message_is_edit (message)) { + priv->unread_messages--; + g_object_notify (G_OBJECT (chat), "nb-unread-messages"); + } } static void -- 2.39.2