From 6712ce9307350ef5c04f184b0cb80cfe75af77c5 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 7 Mar 2019 22:38:02 +0300 Subject: Srmm_ModifyIcon now changes only tooltip and/or icon, Srmm_SetIconFlags controls flags --- plugins/SecureIM/src/crypt_icons.cpp | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) (limited to 'plugins/SecureIM/src') diff --git a/plugins/SecureIM/src/crypt_icons.cpp b/plugins/SecureIM/src/crypt_icons.cpp index 2d08e017e7..bed0d48ad4 100644 --- a/plugins/SecureIM/src/crypt_icons.cpp +++ b/plugins/SecureIM/src/crypt_icons.cpp @@ -79,16 +79,13 @@ void ShowStatusIcon(MCONTACT hContact, int mode) ExtraIcon_Clear(g_hCLIcon, hMC); } - StatusIconData sid = {}; - sid.szModule = (char*)MODULENAME; for (int i = MODE_NATIVE; i < MODE_CNT; i++) { - sid.dwId = i; - sid.flags = (mode & SECURED) ? 0 : MBF_DISABLED; + int flags = (mode & SECURED) ? 0 : MBF_DISABLED; if (mode == -1 || (mode & 0x0f) != i || isChatRoom(hContact)) - sid.flags |= MBF_HIDDEN; // отключаем все ненужные иконки - Srmm_ModifyIcon(hContact, &sid); + flags |= MBF_HIDDEN; // отключаем все ненужные иконки + Srmm_SetIconFlags(hContact, MODULENAME, i, flags); if (hMC) - Srmm_ModifyIcon(hMC, &sid); + Srmm_SetIconFlags(hMC, MODULENAME, i, flags); } } -- cgit v1.2.3