diff options
author | George Hazan <ghazan@miranda.im> | 2018-11-14 16:05:08 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-11-14 16:05:08 +0300 |
commit | 74bea23a96d71d6ecee12a71dd024701c688a477 (patch) | |
tree | 6a66d4cccdd7434f0d9d8f18ef77aed74857435d /plugins/BuddyPounce/src/main.cpp | |
parent | a6b9f6570b4cb4a425f91d4694e6b027f12cc8b7 (diff) |
BuddyPounce -> g_plugin
Diffstat (limited to 'plugins/BuddyPounce/src/main.cpp')
-rw-r--r-- | plugins/BuddyPounce/src/main.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/plugins/BuddyPounce/src/main.cpp b/plugins/BuddyPounce/src/main.cpp index 30a0d2278c..ea2fd39dba 100644 --- a/plugins/BuddyPounce/src/main.cpp +++ b/plugins/BuddyPounce/src/main.cpp @@ -21,7 +21,7 @@ PLUGININFOEX pluginInfoEx = { };
CMPlugin::CMPlugin() :
- PLUGIN<CMPlugin>(MODULENAME, pluginInfoEx)
+ PLUGIN<CMPlugin>("BuddyPounce", pluginInfoEx)
{}
/////////////////////////////////////////////////////////////////////////////////////////
@@ -38,8 +38,8 @@ int MsgAck(WPARAM, LPARAM lParam) // wrtie it to the DB
DBEVENTINFO dbei = {};
DBVARIANT dbv;
- int reuse = db_get_b(ack->hContact, MODULENAME, "Reuse", 0);
- if (!db_get_ws(ack->hContact, MODULENAME, "PounceMsg", &dbv) && (dbv.pwszVal[0] != '\0')) {
+ int reuse = g_plugin.getByte(ack->hContact, "Reuse");
+ if (!g_plugin.getWString(ack->hContact, "PounceMsg", &dbv) && (dbv.pwszVal[0] != '\0')) {
T2Utf pszUtf(dbv.pwszVal);
dbei.eventType = EVENTTYPE_MESSAGE;
dbei.flags = DBEF_UTF | DBEF_SENT;
@@ -51,10 +51,10 @@ int MsgAck(WPARAM, LPARAM lParam) }
// check to reuse
if (reuse > 1)
- db_set_b(ack->hContact, MODULENAME, "Reuse", (BYTE)(reuse - 1));
+ g_plugin.setByte(ack->hContact, "Reuse", (BYTE)(reuse - 1));
else {
- db_set_b(ack->hContact, MODULENAME, "Reuse", 0);
- db_set_ws(ack->hContact, MODULENAME, "PounceMsg", L"");
+ g_plugin.setByte(ack->hContact, "Reuse", 0);
+ g_plugin.setWString(ack->hContact, "PounceMsg", L"");
}
}
WindowList_Remove(hWindowList, (HWND)ack->hProcess);
|