From e441a31e9f912fc8e9244d16560565559b1924d2 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Fri, 27 Sep 2019 23:43:06 +0300 Subject: end of manual experiments with CList/NotOnList --- plugins/Boltun/src/boltun.cpp | 4 ++-- plugins/Boltun/src/stdafx.h | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'plugins/Boltun/src') diff --git a/plugins/Boltun/src/boltun.cpp b/plugins/Boltun/src/boltun.cpp index e50af48380..deb08f133c 100644 --- a/plugins/Boltun/src/boltun.cpp +++ b/plugins/Boltun/src/boltun.cpp @@ -181,7 +181,7 @@ static bool BoltunAutoChat(MCONTACT hContact) return true; } - if ((db_get_b(hContact, "CList", "NotOnList", 0) == 1) && Config.TalkWithNotInList) + if (!Contact_OnList(hContact) && Config.TalkWithNotInList) return true; if (g_plugin.getByte(hContact, DB_CONTACT_BOLTUN_AUTO_CHAT, FALSE) == TRUE) @@ -491,7 +491,7 @@ static int OnContactMenuPrebuild(WPARAM hContact, LPARAM) { INT_PTR flags = CallProtoService(GetContactProto(hContact), PS_GETCAPS, PFLAGNUM_1); - bool bEnable = blInit && !db_get_b(hContact, "CList", "NotOnList", 0) && (flags & PF1_IM) != 0; + bool bEnable = blInit && Contact_OnList(hContact) && (flags & PF1_IM) != 0; Menu_ShowItem(hMenuItemAutoChat, bEnable); Menu_ShowItem(hMenuItemNotToChat, bEnable); Menu_ShowItem(hMenuItemStartChatting, bEnable); diff --git a/plugins/Boltun/src/stdafx.h b/plugins/Boltun/src/stdafx.h index 18153fec0e..7b452aa982 100644 --- a/plugins/Boltun/src/stdafx.h +++ b/plugins/Boltun/src/stdafx.h @@ -34,6 +34,7 @@ #include #include +#include #include #include #include -- cgit v1.2.3