summaryrefslogtreecommitdiff
path: root/plugins/NotesAndReminders
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2018-05-23 23:29:25 +0300
committerGeorge Hazan <ghazan@miranda.im>2018-05-23 23:29:25 +0300
commit176e52e14fd0358a7f26ca8d7b0205244dfde2e7 (patch)
tree10da2f8951d20103af0215c38d07ea96ba61c191 /plugins/NotesAndReminders
parent91b13500b47a51f3a284d9f409b7b8dac167a06d (diff)
no need to initialize pcli variable in each plugin (only in Clist_*)
Diffstat (limited to 'plugins/NotesAndReminders')
-rw-r--r--plugins/NotesAndReminders/src/main.cpp2
-rw-r--r--plugins/NotesAndReminders/src/reminders.cpp6
2 files changed, 3 insertions, 5 deletions
diff --git a/plugins/NotesAndReminders/src/main.cpp b/plugins/NotesAndReminders/src/main.cpp
index d705e5776e..92e83ed312 100644
--- a/plugins/NotesAndReminders/src/main.cpp
+++ b/plugins/NotesAndReminders/src/main.cpp
@@ -1,6 +1,5 @@
#include "globals.h"
-CLIST_INTERFACE *pcli;
CMPlugin g_plugin;
HINSTANCE hmiranda = nullptr;
@@ -269,7 +268,6 @@ int OnModulesLoaded(WPARAM, LPARAM)
extern "C" __declspec(dllexport) int Load(void)
{
- pcli = Clist_GetInterface();
hmiranda = GetModuleHandle(nullptr);
INITCOMMONCONTROLSEX ctrls = { 0 };
diff --git a/plugins/NotesAndReminders/src/reminders.cpp b/plugins/NotesAndReminders/src/reminders.cpp
index e15415e8c4..32adf4521e 100644
--- a/plugins/NotesAndReminders/src/reminders.cpp
+++ b/plugins/NotesAndReminders/src/reminders.cpp
@@ -140,12 +140,12 @@ static void RemoveReminderSystemEvent(REMINDERDATA *p)
{
if (p->SystemEventQueued) {
for (int i = 0;; i++) {
- CLISTEVENT *pev = pcli->pfnGetEvent(-1, i);
+ CLISTEVENT *pev = g_CLI.pfnGetEvent(-1, i);
if (!pev)
break;
if ((ULONG)pev->lParam == p->uid && !pev->hContact && pev->pszService && !mir_strcmp(pev->pszService, MODULENAME"/OpenTriggeredReminder")) {
- if (!pcli->pfnRemoveEvent(pev->hContact, pev->hDbEvent)) {
+ if (!g_CLI.pfnRemoveEvent(pev->hContact, pev->hDbEvent)) {
p->SystemEventQueued = FALSE;
if (QueuedReminderCount)
QueuedReminderCount--;
@@ -529,7 +529,7 @@ static void FireReminder(REMINDERDATA *pReminder, BOOL *pHasPlayedSound)
ev.lParam = (LPARAM)pReminder->uid;
ev.pszService = MODULENAME"/OpenTriggeredReminder";
ev.szTooltip.a = Translate("Reminder");
- pcli->pfnAddEvent(&ev);
+ g_CLI.pfnAddEvent(&ev);
}
pReminder->SystemEventQueued = TRUE;