summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2022-06-22 18:59:31 +0300
committerGeorge Hazan <ghazan@miranda.im>2022-06-22 18:59:31 +0300
commit6c10f6b8b8564337fb5fb88d31f2403ec2ccce9e (patch)
tree254f2534c1f8e7f7dc928461160e5b9519fd3a8f
parentda5eb4e6c9725aca51f8de23a5cb89ee5b6b3087 (diff)
fixes #3108 (NewEventNotify shows message popup even if antispam is enabled)
-rw-r--r--plugins/NewEventNotify/src/main.cpp4
-rw-r--r--plugins/NewEventNotify/src/options.cpp2
-rw-r--r--plugins/StopSpamPlus/src/events.cpp7
3 files changed, 5 insertions, 8 deletions
diff --git a/plugins/NewEventNotify/src/main.cpp b/plugins/NewEventNotify/src/main.cpp
index 60692ec06b..d0ae746562 100644
--- a/plugins/NewEventNotify/src/main.cpp
+++ b/plugins/NewEventNotify/src/main.cpp
@@ -78,11 +78,11 @@ int HookedNewEvent(WPARAM hContact, LPARAM hDbEvent)
if (pei && pei->flags & DETF_NONOTIFY)
return 0;
- //if event was allready read don't show it
+ // if event was allready read don't show it
if (g_plugin.bReadCheck && (dbe.flags & DBEF_READ))
return 0;
- //is it an event sent by the user? -> don't show
+ // is it an event sent by the user? -> don't show
if (dbe.flags & DBEF_SENT) {
// JK, only message event, do not influence others
auto *pdata = PU_GetByContact(hContact, EVENTTYPE_MESSAGE);
diff --git a/plugins/NewEventNotify/src/options.cpp b/plugins/NewEventNotify/src/options.cpp
index 8820ec597e..43e4d2d950 100644
--- a/plugins/NewEventNotify/src/options.cpp
+++ b/plugins/NewEventNotify/src/options.cpp
@@ -65,7 +65,7 @@ void CMPlugin::OptionsRead(void)
bShowON = getBool(OPT_SHOW_ON, true);
bHideSend = getBool(OPT_HIDESEND, true);
bNoRSS = getBool(OPT_NORSS, false);
- bReadCheck = getBool(OPT_READCHECK, false);
+ bReadCheck = getBool(OPT_READCHECK, true);
}
void CMPlugin::OptionsWrite(void)
diff --git a/plugins/StopSpamPlus/src/events.cpp b/plugins/StopSpamPlus/src/events.cpp
index 10f69769ac..8985820c07 100644
--- a/plugins/StopSpamPlus/src/events.cpp
+++ b/plugins/StopSpamPlus/src/events.cpp
@@ -145,12 +145,9 @@ int OnDbEventFilterAdd(WPARAM w, LPARAM l)
Contact_RemoveFromList(hContact);
Contact_Hide(hContact);
- // save message from contact
+ // mark message as read and allow to insert it into the history
dbei->flags |= DBEF_READ;
- db_event_add(hContact, dbei);
-
- // reject processing of the event
- return 1;
+ return 0;
}
int OnDbContactSettingchanged(WPARAM hContact, LPARAM l)