From f6f0238e4b6d36fbc4d523382d55ebbfe08ed31a Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 30 Aug 2018 12:58:02 +0300 Subject: fix of wrong status change processing, caused by a patch for #1304 fixes #1321 (When connecting to only some protocols, the notification area icon shows offline icon) --- src/mir_app/src/clc.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src/mir_app') diff --git a/src/mir_app/src/clc.cpp b/src/mir_app/src/clc.cpp index 40f6b5e6cb..6758a23958 100644 --- a/src/mir_app/src/clc.cpp +++ b/src/mir_app/src/clc.cpp @@ -136,14 +136,15 @@ static int ClcProtoAck(WPARAM, LPARAM lParam) if (ack->type == ACKTYPE_STATUS) { if (ack->result == ACKRESULT_SUCCESS) { PROTOACCOUNT *pa = Proto_GetAccount(ack->szModule); - if (pa) { + if (pa) pa->iRealStatus = ack->lParam; - Clist_TrayIconUpdateBase(ack->szModule); - } } - + g_clistApi.pfnCluiProtocolStatusChanged(lParam, ack->szModule); + if (ack->result == ACKRESULT_SUCCESS) + Clist_TrayIconUpdateBase(ack->szModule); + if ((INT_PTR)ack->hProcess < ID_STATUS_ONLINE && ack->lParam >= ID_STATUS_ONLINE) { // if we're going offline, kill all contacts scheduled for deletion DWORD caps = (DWORD)CallProtoServiceInt(0, ack->szModule, PS_GETCAPS, PFLAGNUM_1, 0); -- cgit v1.2.3