From 496cd8776e8fcf49284717fa717e8bbe620bcc3f Mon Sep 17 00:00:00 2001 From: George Hazan Date: Fri, 22 Dec 2023 17:56:49 +0300 Subject: fixes #4000 completely --- include/m_clistint.h | 1 + src/mir_app/src/srmm_util.cpp | 3 +++ 2 files changed, 4 insertions(+) diff --git a/include/m_clistint.h b/include/m_clistint.h index 168d8fb0ec..d2fa84bc3b 100644 --- a/include/m_clistint.h +++ b/include/m_clistint.h @@ -290,6 +290,7 @@ MIR_APP_DLL(int) Clist_TrayIconSetBaseInfo(HICON hIcon, const char *szPref MIR_APP_DLL(void) Clist_TrayIconUpdateBase(const char *szChangedProto); MIR_APP_DLL(void) Clist_TraySetTimer(); +MIR_APP_DLL(CListEvent*) Clist_FindEvent(MCONTACT hContact, MEVENT hDbEvent); MIR_APP_DLL(CListEvent*) Clist_GetEvent(MCONTACT hContact, int idx); MIR_APP_DLL(CListEvent*) Clist_GetEventByMenu(int iMenuId); diff --git a/src/mir_app/src/srmm_util.cpp b/src/mir_app/src/srmm_util.cpp index 978ebd8aa8..f20067fa77 100644 --- a/src/mir_app/src/srmm_util.cpp +++ b/src/mir_app/src/srmm_util.cpp @@ -31,6 +31,9 @@ const char *g_pszHotkeySection; MIR_APP_DLL(void) Srmm_AddEvent(MCONTACT hContact, MEVENT hDbEvent) { + if (Clist_FindEvent(hContact, hDbEvent)) + return; + wchar_t toolTip[256]; mir_snwprintf(toolTip, TranslateT("Message from %s"), Clist_GetContactDisplayName(hContact)); -- cgit v1.2.3