summaryrefslogtreecommitdiff
path: root/plugins/QuickMessages/src/Utils.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/QuickMessages/src/Utils.cpp')
-rw-r--r--plugins/QuickMessages/src/Utils.cpp40
1 files changed, 20 insertions, 20 deletions
diff --git a/plugins/QuickMessages/src/Utils.cpp b/plugins/QuickMessages/src/Utils.cpp
index 1fa555b4c6..626df47e54 100644
--- a/plugins/QuickMessages/src/Utils.cpp
+++ b/plugins/QuickMessages/src/Utils.cpp
@@ -153,22 +153,22 @@ void SaveModuleSettings(int buttonnum, ButtonData* bd)
char szMEntry[256] = { '\0' };
mir_snprintf(szMEntry, "EntryName_%u_%u", buttonnum, bd->dwPos);
- db_set_ws(NULL, PLGNAME, szMEntry, bd->pszName);
+ db_set_ws(NULL, MODULENAME, szMEntry, bd->pszName);
mir_snprintf(szMEntry, "EntryValue_%u_%u", buttonnum, bd->dwPos);
if (bd->pszValue)
- db_set_ws(NULL, PLGNAME, szMEntry, bd->pszValue);
+ db_set_ws(NULL, MODULENAME, szMEntry, bd->pszValue);
else
- db_unset(NULL, PLGNAME, szMEntry);
+ db_unset(NULL, MODULENAME, szMEntry);
mir_snprintf(szMEntry, "EntryRel_%u_%u", buttonnum, bd->dwPos);
- db_set_b(NULL, PLGNAME, szMEntry, bd->fEntryType);
+ db_set_b(NULL, MODULENAME, szMEntry, bd->fEntryType);
mir_snprintf(szMEntry, "EntryToQMenu_%u_%u", buttonnum, bd->dwPos);
- db_set_b(NULL, PLGNAME, szMEntry, bd->bInQMenu);
+ db_set_b(NULL, MODULENAME, szMEntry, bd->bInQMenu);
mir_snprintf(szMEntry, "EntryIsServiceName_%u_%u", buttonnum, bd->dwPos);
- db_set_b(NULL, PLGNAME, szMEntry, bd->bIsServName);
+ db_set_b(NULL, MODULENAME, szMEntry, bd->bIsServName);
}
void CleanSettings(int buttonnum, int from)
@@ -177,24 +177,24 @@ void CleanSettings(int buttonnum, int from)
DBVARIANT dbv = { 0 };
if (from == -1) {
mir_snprintf(szMEntry, "ButtonName_%u", buttonnum);
- db_unset(NULL, PLGNAME, szMEntry);
+ db_unset(NULL, MODULENAME, szMEntry);
mir_snprintf(szMEntry, "ButtonValue_%u", buttonnum);
- db_unset(NULL, PLGNAME, szMEntry);
+ db_unset(NULL, MODULENAME, szMEntry);
mir_snprintf(szMEntry, "RCEntryIsServiceName_%u", buttonnum);
- db_unset(NULL, PLGNAME, szMEntry);
+ db_unset(NULL, MODULENAME, szMEntry);
}
mir_snprintf(szMEntry, "EntryName_%u_%u", buttonnum, from);
- while (!db_get_ws(NULL, PLGNAME, szMEntry, &dbv)) {
- db_unset(NULL, PLGNAME, szMEntry);
+ while (!db_get_ws(NULL, MODULENAME, szMEntry, &dbv)) {
+ db_unset(NULL, MODULENAME, szMEntry);
mir_snprintf(szMEntry, "EntryValue_%u_%u", buttonnum, from);
- db_unset(NULL, PLGNAME, szMEntry);
+ db_unset(NULL, MODULENAME, szMEntry);
mir_snprintf(szMEntry, "EntryRel_%u_%u", buttonnum, from);
- db_unset(NULL, PLGNAME, szMEntry);
+ db_unset(NULL, MODULENAME, szMEntry);
mir_snprintf(szMEntry, "EntryToQMenu_%u_%u", buttonnum, from);
- db_unset(NULL, PLGNAME, szMEntry);
+ db_unset(NULL, MODULENAME, szMEntry);
mir_snprintf(szMEntry, "EntryIsServiceName_%u_%u", buttonnum, from);
- db_unset(NULL, PLGNAME, szMEntry);
+ db_unset(NULL, MODULENAME, szMEntry);
mir_snprintf(szMEntry, "EntryName_%u_%u", buttonnum, ++from);
}
@@ -219,7 +219,7 @@ BYTE getEntryByte(int buttonnum, int entrynum, BOOL mode)
mir_snprintf(szMEntry, "RCEntryIsServiceName_%u", buttonnum);
break;
}
- return db_get_b(NULL, PLGNAME, szMEntry, 0);
+ return db_get_b(NULL, MODULENAME, szMEntry, 0);
}
static HANDLE AddIcon(char* szIcoName)
@@ -240,7 +240,7 @@ static HANDLE AddIcon(char* szIcoName)
DWORD BalanceButtons(int buttonsWas, int buttonsNow)
{
BBButton bb = {};
- bb.pszModuleName = PLGNAME;
+ bb.pszModuleName = MODULENAME;
while (buttonsWas > buttonsNow) {
bb.dwButtonID = --buttonsWas;
@@ -270,7 +270,7 @@ void InitButtonsList()
ListData* ld = nullptr;
if (!(pszBName = getMenuEntry(i, 0, 3))) {
g_iButtonsCount = i;
- db_set_b(NULL, PLGNAME, "ButtonsCount", (BYTE)g_iButtonsCount);
+ db_set_b(NULL, MODULENAME, "ButtonsCount", (BYTE)g_iButtonsCount);
break;
}
@@ -352,7 +352,7 @@ wchar_t* getMenuEntry(int buttonnum, int entrynum, BYTE mode)
break;
}
- if (!db_get_ws(NULL, PLGNAME, szMEntry, &dbv)) {
+ if (!db_get_ws(NULL, MODULENAME, szMEntry, &dbv)) {
if (mir_wstrlen(dbv.ptszVal))
buffer = mir_wstrdup(dbv.ptszVal);
db_free(&dbv);
@@ -374,7 +374,7 @@ int RegisterCustomButton(WPARAM, LPARAM)
bbd.dwButtonID = i;
bbd.dwDefPos = 320 + i;
bbd.hIcon = AddIcon(iconname);
- bbd.pszModuleName = PLGNAME;
+ bbd.pszModuleName = MODULENAME;
bbd.pwszTooltip = ld->ptszButtonName;
Srmm_AddButton(&bbd);
}