diff options
author | George Hazan <george.hazan@gmail.com> | 2015-06-04 22:12:13 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2015-06-04 22:12:13 +0000 |
commit | b7c74cd5b22618d544a3f4ae124985d4837e3a22 (patch) | |
tree | 468d9610a590685322ad2159a9bd2d9e2ba83f89 /plugins/Clist_nicer | |
parent | 7de513f180c429859e246d1033d745b394e1fc28 (diff) |
new mir_snprintf templates without SIZEOF
git-svn-id: http://svn.miranda-ng.org/main/trunk@14002 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Clist_nicer')
-rw-r--r-- | plugins/Clist_nicer/src/CLUIFrames/groupmenu.cpp | 4 | ||||
-rw-r--r-- | plugins/Clist_nicer/src/clcitems.cpp | 2 | ||||
-rw-r--r-- | plugins/Clist_nicer/src/clui.cpp | 6 | ||||
-rw-r--r-- | plugins/Clist_nicer/src/cluiopts.cpp | 4 | ||||
-rw-r--r-- | plugins/Clist_nicer/src/extBackg.cpp | 56 | ||||
-rw-r--r-- | plugins/Clist_nicer/src/viewmodes.cpp | 48 |
6 files changed, 60 insertions, 60 deletions
diff --git a/plugins/Clist_nicer/src/CLUIFrames/groupmenu.cpp b/plugins/Clist_nicer/src/CLUIFrames/groupmenu.cpp index 5634ab1cc1..e2ef621a41 100644 --- a/plugins/Clist_nicer/src/CLUIFrames/groupmenu.cpp +++ b/plugins/Clist_nicer/src/CLUIFrames/groupmenu.cpp @@ -93,7 +93,7 @@ static INT_PTR AddGroupMenuItem(WPARAM wParam, LPARAM lParam) tmi.ownerdata = mmep;
char buf[1024];
- mir_snprintf(buf, SIZEOF(buf), "%s/%s", mi->pszService, mi->pszName);
+ mir_snprintf(buf, "%s/%s", mi->pszService, mi->pszName);
OptParam op;
op.Handle = (HANDLE)CallService(MO_ADDNEWMENUITEM, (WPARAM)hGroupMenuObject, (LPARAM)&tmi);
@@ -428,7 +428,7 @@ static INT_PTR AddSubGroupMenuItem(WPARAM wParam, LPARAM lParam) tmi.ownerdata = mmep;
char buf[1024];
- mir_snprintf(buf, SIZEOF(buf), "%s/%s", mi->pszService, mi->pszName);
+ mir_snprintf(buf, "%s/%s", mi->pszService, mi->pszName);
OptParam op;
op.Handle = (HANDLE)CallService(MO_ADDNEWMENUITEM, (WPARAM)hSubGroupMenuObject, (LPARAM)&tmi);
diff --git a/plugins/Clist_nicer/src/clcitems.cpp b/plugins/Clist_nicer/src/clcitems.cpp index 2d1cf246f3..c171a09813 100644 --- a/plugins/Clist_nicer/src/clcitems.cpp +++ b/plugins/Clist_nicer/src/clcitems.cpp @@ -480,7 +480,7 @@ int __fastcall CLVM_GetContactHiddenStatus(MCONTACT hContact, char *szProto, str }
// check the proto, use it as a base filter result for all further checks
if (cfg::dat.bFilterEffective & CLVM_FILTER_PROTOS) {
- mir_snprintf(szTemp, SIZEOF(szTemp), "%s|", szProto);
+ mir_snprintf(szTemp, "%s|", szProto);
filterResult = strstr(cfg::dat.protoFilter, szTemp) ? 1 : 0;
}
if (cfg::dat.bFilterEffective & CLVM_FILTER_GROUPS) {
diff --git a/plugins/Clist_nicer/src/clui.cpp b/plugins/Clist_nicer/src/clui.cpp index 3d3f28348a..096fe9ff54 100644 --- a/plugins/Clist_nicer/src/clui.cpp +++ b/plugins/Clist_nicer/src/clui.cpp @@ -1618,7 +1618,7 @@ buttons_done: GetWindowRect(pcli->hwndContactTree, &rc); // x/y might be -1 if it was generated by a kb click - POINT pt = { GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam) };
+ POINT pt = { GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam) }; if (pt.x == -1 && pt.y == -1) { // all this is done in screen-coords! GetCursorPos(&pt); @@ -1851,7 +1851,7 @@ INT_PTR CALLBACK DlgProcAbout(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPar { char str[64]; DWORD v = pluginInfo.version; - mir_snprintf(str, SIZEOF(str), "%s %d.%d.%d.%d", Translate("Version"), HIBYTE(HIWORD(v)), LOBYTE(HIWORD(v)), HIBYTE(LOWORD(v)), LOBYTE(LOWORD(v))); + mir_snprintf(str, "%s %d.%d.%d.%d", Translate("Version"), HIBYTE(HIWORD(v)), LOBYTE(HIWORD(v)), HIBYTE(LOWORD(v)), LOBYTE(LOWORD(v))); SetDlgItemTextA(hwndDlg, IDC_VERSION, str); } { @@ -2033,7 +2033,7 @@ void FS_RegisterFonts() _tcsncpy(fid.name, clistFontDescr[i].tszName, SIZEOF(fid.name)); char idstr[10]; - mir_snprintf(idstr, SIZEOF(idstr), "Font%d", i); + mir_snprintf(idstr, "Font%d", i); strncpy(fid.prefix, idstr, SIZEOF(fid.prefix)); fid.order = i; FontRegisterT(&fid); diff --git a/plugins/Clist_nicer/src/cluiopts.cpp b/plugins/Clist_nicer/src/cluiopts.cpp index baa147581a..7fac4e76ba 100644 --- a/plugins/Clist_nicer/src/cluiopts.cpp +++ b/plugins/Clist_nicer/src/cluiopts.cpp @@ -152,9 +152,9 @@ INT_PTR CALLBACK DlgProcCluiOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l case WM_HSCROLL:
{
char str[10];
- mir_snprintf(str, SIZEOF(str), "%d%%", 100 * SendDlgItemMessage(hwndDlg, IDC_TRANSINACTIVE, TBM_GETPOS, 0, 0) / 255);
+ mir_snprintf(str, "%d%%", 100 * SendDlgItemMessage(hwndDlg, IDC_TRANSINACTIVE, TBM_GETPOS, 0, 0) / 255);
SetDlgItemTextA(hwndDlg, IDC_INACTIVEPERC, str);
- mir_snprintf(str, SIZEOF(str), "%d%%", 100 * SendDlgItemMessage(hwndDlg, IDC_TRANSACTIVE, TBM_GETPOS, 0, 0) / 255);
+ mir_snprintf(str, "%d%%", 100 * SendDlgItemMessage(hwndDlg, IDC_TRANSACTIVE, TBM_GETPOS, 0, 0) / 255);
SetDlgItemTextA(hwndDlg, IDC_ACTIVEPERC, str);
}
if (wParam != 0x12345678) {
diff --git a/plugins/Clist_nicer/src/extBackg.cpp b/plugins/Clist_nicer/src/extBackg.cpp index f569932195..2c9b7f4e74 100644 --- a/plugins/Clist_nicer/src/extBackg.cpp +++ b/plugins/Clist_nicer/src/extBackg.cpp @@ -302,7 +302,7 @@ void LoadExtBkSettingsFromDB() continue;
p->imageItem = 0;
- char buffer[255], *pszEnd = buffer + mir_snprintf(buffer, SIZEOF(buffer), "%s_", p->szDBname);
+ char buffer[255], *pszEnd = buffer + mir_snprintf(buffer, "%s_", p->szDBname);
mir_strcpy(pszEnd, "IGNORE"); p->IGNORED = (BYTE)cfg::getByte("CLCExt", buffer, p->IGNORED);
mir_strcpy(pszEnd, "GRADIENT"); p->GRADIENT = (BYTE)cfg::getDword("CLCExt", buffer, p->GRADIENT);
mir_strcpy(pszEnd, "CORNER"); p->CORNER = (BYTE)cfg::getDword("CLCExt", buffer, p->CORNER);
@@ -338,31 +338,31 @@ static void SaveCompleteStructToDB() StatusItems_t *p = arStatusItems[n];
if (p->statusID != ID_EXTBKSEPARATOR) {
char buffer[255];
- mir_snprintf(buffer, SIZEOF(buffer), "%s_IGNORE", p->szDBname);
+ mir_snprintf(buffer, "%s_IGNORE", p->szDBname);
cfg::writeByte("CLCExt", buffer, p->IGNORED);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_GRADIENT", p->szDBname);
+ mir_snprintf(buffer, "%s_GRADIENT", p->szDBname);
cfg::writeDword("CLCExt", buffer, p->GRADIENT);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_CORNER", p->szDBname);
+ mir_snprintf(buffer, "%s_CORNER", p->szDBname);
cfg::writeDword("CLCExt", buffer, p->CORNER);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_COLOR", p->szDBname);
+ mir_snprintf(buffer, "%s_COLOR", p->szDBname);
cfg::writeDword("CLCExt", buffer, p->COLOR);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_COLOR2", p->szDBname);
+ mir_snprintf(buffer, "%s_COLOR2", p->szDBname);
cfg::writeDword("CLCExt", buffer, p->COLOR2);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_COLOR2_TRANSPARENT", p->szDBname);
+ mir_snprintf(buffer, "%s_COLOR2_TRANSPARENT", p->szDBname);
cfg::writeByte("CLCExt", buffer, p->COLOR2_TRANSPARENT);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_TEXTCOLOR", p->szDBname);
+ mir_snprintf(buffer, "%s_TEXTCOLOR", p->szDBname);
cfg::writeDword("CLCExt", buffer, p->TEXTCOLOR);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_ALPHA", p->szDBname);
+ mir_snprintf(buffer, "%s_ALPHA", p->szDBname);
cfg::writeByte("CLCExt", buffer, (BYTE)p->ALPHA);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_MRGN_LEFT", p->szDBname);
+ mir_snprintf(buffer, "%s_MRGN_LEFT", p->szDBname);
cfg::writeByte("CLCExt", buffer, (BYTE)p->MARGIN_LEFT);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_MRGN_TOP", p->szDBname);
+ mir_snprintf(buffer, "%s_MRGN_TOP", p->szDBname);
cfg::writeByte("CLCExt", buffer, (BYTE)p->MARGIN_TOP);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_MRGN_RIGHT", p->szDBname);
+ mir_snprintf(buffer, "%s_MRGN_RIGHT", p->szDBname);
cfg::writeByte("CLCExt", buffer, (BYTE)p->MARGIN_RIGHT);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_MRGN_BOTTOM", p->szDBname);
+ mir_snprintf(buffer, "%s_MRGN_BOTTOM", p->szDBname);
cfg::writeByte("CLCExt", buffer, (BYTE)p->MARGIN_BOTTOM);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_BDRSTYLE", p->szDBname);
+ mir_snprintf(buffer, "%s_BDRSTYLE", p->szDBname);
cfg::writeDword("CLCExt", buffer, p->BORDERSTYLE);
}
}
@@ -470,7 +470,7 @@ void extbk_export(char *file) if (p->statusID == ID_EXTBKSEPARATOR)
continue;
- char *pszEnd = buffer + mir_snprintf(buffer, SIZEOF(buffer), "%s_", p->szDBname);
+ char *pszEnd = buffer + mir_snprintf(buffer, "%s_", p->szDBname);
mir_strcpy(pszEnd, "ALPHA"); WritePrivateProfileStructA("ExtBKSettings", buffer, &(p->ALPHA), sizeof(p->ALPHA), file);
mir_strcpy(pszEnd, "COLOR"); WritePrivateProfileStructA("ExtBKSettings", buffer, &(p->COLOR), sizeof(p->COLOR), file);
mir_strcpy(pszEnd, "COLOR2"); WritePrivateProfileStructA("ExtBKSettings", buffer, &(p->COLOR2), sizeof(p->COLOR2), file);
@@ -1331,31 +1331,31 @@ void extbk_import(char *file, HWND hwndDlg) if (p->statusID == ID_EXTBKSEPARATOR)
continue;
- mir_snprintf(buffer, SIZEOF(buffer), "%s_ALPHA", p->szDBname);
+ mir_snprintf(buffer, "%s_ALPHA", p->szDBname);
GetPrivateProfileStructA("ExtBKSettings", buffer, &(p->ALPHA), sizeof(p->ALPHA), file);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_COLOR", p->szDBname);
+ mir_snprintf(buffer, "%s_COLOR", p->szDBname);
GetPrivateProfileStructA("ExtBKSettings", buffer, &(p->COLOR), sizeof(p->COLOR), file);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_COLOR2", p->szDBname);
+ mir_snprintf(buffer, "%s_COLOR2", p->szDBname);
GetPrivateProfileStructA("ExtBKSettings", buffer, &(p->COLOR2), sizeof(p->COLOR2), file);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_COLOR2_TRANSPARENT", p->szDBname);
+ mir_snprintf(buffer, "%s_COLOR2_TRANSPARENT", p->szDBname);
GetPrivateProfileStructA("ExtBKSettings", buffer, &(p->COLOR2_TRANSPARENT), sizeof(p->COLOR2_TRANSPARENT), file);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_TEXTCOLOR", p->szDBname);
+ mir_snprintf(buffer, "%s_TEXTCOLOR", p->szDBname);
GetPrivateProfileStructA("ExtBKSettings", buffer, &(p->TEXTCOLOR), sizeof(p->TEXTCOLOR), file);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_CORNER", p->szDBname);
+ mir_snprintf(buffer, "%s_CORNER", p->szDBname);
GetPrivateProfileStructA("ExtBKSettings", buffer, &(p->CORNER), sizeof(p->CORNER), file);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_GRADIENT", p->szDBname);
+ mir_snprintf(buffer, "%s_GRADIENT", p->szDBname);
GetPrivateProfileStructA("ExtBKSettings", buffer, &(p->GRADIENT), sizeof(p->GRADIENT), file);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_IGNORED", p->szDBname);
+ mir_snprintf(buffer, "%s_IGNORED", p->szDBname);
GetPrivateProfileStructA("ExtBKSettings", buffer, &(p->IGNORED), sizeof(p->IGNORED), file);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_MARGIN_BOTTOM", p->szDBname);
+ mir_snprintf(buffer, "%s_MARGIN_BOTTOM", p->szDBname);
GetPrivateProfileStructA("ExtBKSettings", buffer, &(p->MARGIN_BOTTOM), sizeof(p->MARGIN_BOTTOM), file);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_MARGIN_LEFT", p->szDBname);
+ mir_snprintf(buffer, "%s_MARGIN_LEFT", p->szDBname);
GetPrivateProfileStructA("ExtBKSettings", buffer, &(p->MARGIN_LEFT), sizeof(p->MARGIN_LEFT), file);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_MARGIN_RIGHT", p->szDBname);
+ mir_snprintf(buffer, "%s_MARGIN_RIGHT", p->szDBname);
GetPrivateProfileStructA("ExtBKSettings", buffer, &(p->MARGIN_RIGHT), sizeof(p->MARGIN_RIGHT), file);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_MARGIN_TOP", p->szDBname);
+ mir_snprintf(buffer, "%s_MARGIN_TOP", p->szDBname);
GetPrivateProfileStructA("ExtBKSettings", buffer, &(p->MARGIN_TOP), sizeof(p->MARGIN_TOP), file);
- mir_snprintf(buffer, SIZEOF(buffer), "%s_BORDERSTYLE", p->szDBname);
+ mir_snprintf(buffer, "%s_BORDERSTYLE", p->szDBname);
GetPrivateProfileStructA("ExtBKSettings", buffer, &(p->BORDERSTYLE), sizeof(p->BORDERSTYLE), file);
}
diff --git a/plugins/Clist_nicer/src/viewmodes.cpp b/plugins/Clist_nicer/src/viewmodes.cpp index b2d6d8e753..7903d52204 100644 --- a/plugins/Clist_nicer/src/viewmodes.cpp +++ b/plugins/Clist_nicer/src/viewmodes.cpp @@ -302,17 +302,17 @@ void SaveViewMode(const char *name, const TCHAR *szGroupFilter, const char *szPr {
char szSetting[512];
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_PF", 246, name);
+ mir_snprintf(szSetting, "%c%s_PF", 246, name);
cfg::writeString(NULL, CLVM_MODULE, szSetting, szProtoFilter);
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_GF", 246, name);
+ mir_snprintf(szSetting, "%c%s_GF", 246, name);
cfg::writeTString(NULL, CLVM_MODULE, szSetting, szGroupFilter);
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_SM", 246, name);
+ mir_snprintf(szSetting, "%c%s_SM", 246, name);
cfg::writeDword(CLVM_MODULE, szSetting, statusMask);
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_SSM", 246, name);
+ mir_snprintf(szSetting, "%c%s_SSM", 246, name);
cfg::writeDword(CLVM_MODULE, szSetting, stickyStatusMask);
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_OPT", 246, name);
+ mir_snprintf(szSetting, "%c%s_OPT", 246, name);
cfg::writeDword(CLVM_MODULE, szSetting, options);
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_LM", 246, name);
+ mir_snprintf(szSetting, "%c%s_LM", 246, name);
cfg::writeDword(CLVM_MODULE, szSetting, lmdat);
cfg::writeDword(CLVM_MODULE, name, MAKELONG((unsigned short)operators, (unsigned short)stickies));
@@ -449,21 +449,21 @@ void UpdateFilters() SendDlgItemMessageA(clvmHwnd, IDC_VIEWMODES, LB_GETTEXT, clvm_curItem, (LPARAM)szBuf);
strncpy(g_szModename, szBuf, sizeof(g_szModename));
g_szModename[sizeof(g_szModename) - 1] = 0;
- mir_snprintf(szTemp, SIZEOF(szTemp), Translate("Current view mode: %s"), g_szModename);
+ mir_snprintf(szTemp, Translate("Current view mode: %s"), g_szModename);
SetDlgItemTextA(clvmHwnd, IDC_CURVIEWMODE2, szTemp);
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_PF", 246, szBuf);
+ mir_snprintf(szSetting, "%c%s_PF", 246, szBuf);
if (db_get(NULL, CLVM_MODULE, szSetting, &dbv_pf))
goto cleanup;
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_GF", 246, szBuf);
+ mir_snprintf(szSetting, "%c%s_GF", 246, szBuf);
if (cfg::getTString(NULL, CLVM_MODULE, szSetting, &dbv_gf))
goto cleanup;
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_OPT", 246, szBuf);
+ mir_snprintf(szSetting, "%c%s_OPT", 246, szBuf);
if ((opt = cfg::getDword(NULL, CLVM_MODULE, szSetting, -1)) != -1) {
SendDlgItemMessage(clvmHwnd, IDC_AUTOCLEARSPIN, UDM_SETPOS, 0, MAKELONG(LOWORD(opt), 0));
}
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_SM", 246, szBuf);
+ mir_snprintf(szSetting, "%c%s_SM", 246, szBuf);
statusMask = cfg::getDword(CLVM_MODULE, szSetting, -1);
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_SSM", 246, szBuf);
+ mir_snprintf(szSetting, "%c%s_SSM", 246, szBuf);
stickyStatusMask = cfg::getDword(CLVM_MODULE, szSetting, -1);
dwFlags = cfg::getDword(CLVM_MODULE, szBuf, 0);
{
@@ -538,7 +538,7 @@ void UpdateFilters() Utils::enableDlgControl(clvmHwnd, IDC_LASTMSGVALUE, useLastMsg);
Utils::enableDlgControl(clvmHwnd, IDC_LASTMESSAGEUNIT, useLastMsg);
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_LM", 246, szBuf);
+ mir_snprintf(szSetting, "%c%s_LM", 246, szBuf);
lmdat = cfg::getDword(CLVM_MODULE, szSetting, 0);
SetDlgItemInt(clvmHwnd, IDC_LASTMSGVALUE, LOWORD(lmdat), FALSE);
@@ -652,15 +652,15 @@ INT_PTR CALLBACK DlgProcViewModesSetup(HWND hwndDlg, UINT msg, WPARAM wParam, LP char *szBuf = (char*)malloc(iLen + 1);
if (szBuf) {
SendDlgItemMessageA(hwndDlg, IDC_VIEWMODES, LB_GETTEXT, SendDlgItemMessage(hwndDlg, IDC_VIEWMODES, LB_GETCURSEL, 0, 0), (LPARAM)szBuf);
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_PF", 246, szBuf);
+ mir_snprintf(szSetting, "%c%s_PF", 246, szBuf);
db_unset(NULL, CLVM_MODULE, szSetting);
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_GF", 246, szBuf);
+ mir_snprintf(szSetting, "%c%s_GF", 246, szBuf);
db_unset(NULL, CLVM_MODULE, szSetting);
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_SM", 246, szBuf);
+ mir_snprintf(szSetting, "%c%s_SM", 246, szBuf);
db_unset(NULL, CLVM_MODULE, szSetting);
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_VA", 246, szBuf);
+ mir_snprintf(szSetting, "%c%s_VA", 246, szBuf);
db_unset(NULL, CLVM_MODULE, szSetting);
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_SSM", 246, szBuf);
+ mir_snprintf(szSetting, "%c%s_SSM", 246, szBuf);
db_unset(NULL, CLVM_MODULE, szSetting);
db_unset(NULL, CLVM_MODULE, szBuf);
if (!mir_strcmp(cfg::dat.current_viewmode, szBuf) && mir_strlen(szBuf) == mir_strlen(cfg::dat.current_viewmode)) {
@@ -1048,7 +1048,7 @@ void ApplyViewMode(const char *name) cfg::dat.bFilterEffective = 0;
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_PF", 246, name);
+ mir_snprintf(szSetting, "%c%s_PF", 246, name);
if (!cfg::getString(NULL, CLVM_MODULE, szSetting, &dbv)) {
if (mir_strlen(dbv.pszVal) >= 2) {
strncpy(cfg::dat.protoFilter, dbv.pszVal, sizeof(cfg::dat.protoFilter));
@@ -1057,7 +1057,7 @@ void ApplyViewMode(const char *name) }
mir_free(dbv.pszVal);
}
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_GF", 246, name);
+ mir_snprintf(szSetting, "%c%s_GF", 246, name);
if (!cfg::getTString(NULL, CLVM_MODULE, szSetting, &dbv)) {
if (mir_tstrlen(dbv.ptszVal) >= 2) {
_tcsncpy(cfg::dat.groupFilter, dbv.ptszVal, SIZEOF(cfg::dat.groupFilter));
@@ -1066,12 +1066,12 @@ void ApplyViewMode(const char *name) }
mir_free(dbv.ptszVal);
}
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_SM", 246, name);
+ mir_snprintf(szSetting, "%c%s_SM", 246, name);
cfg::dat.statusMaskFilter = cfg::getDword(CLVM_MODULE, szSetting, -1);
if (cfg::dat.statusMaskFilter >= 1)
cfg::dat.bFilterEffective |= CLVM_FILTER_STATUS;
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_SSM", 246, name);
+ mir_snprintf(szSetting, "%c%s_SSM", 246, name);
cfg::dat.stickyMaskFilter = cfg::getDword(CLVM_MODULE, szSetting, -1);
if (cfg::dat.stickyMaskFilter != -1)
cfg::dat.bFilterEffective |= CLVM_FILTER_STICKYSTATUS;
@@ -1082,7 +1082,7 @@ void ApplyViewMode(const char *name) if (cfg::dat.filterFlags & CLVM_AUTOCLEAR) {
DWORD timerexpire;
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_OPT", 246, name);
+ mir_snprintf(szSetting, "%c%s_OPT", 246, name);
timerexpire = LOWORD(cfg::getDword(CLVM_MODULE, szSetting, 0));
strncpy(cfg::dat.old_viewmode, cfg::dat.current_viewmode, 256);
cfg::dat.old_viewmode[255] = 0;
@@ -1103,7 +1103,7 @@ void ApplyViewMode(const char *name) cfg::dat.sortOrder[0] = bSaved;
cfg::dat.bFilterEffective |= CLVM_FILTER_LASTMSG;
- mir_snprintf(szSetting, SIZEOF(szSetting), "%c%s_LM", 246, name);
+ mir_snprintf(szSetting, "%c%s_LM", 246, name);
cfg::dat.lastMsgFilter = cfg::getDword(CLVM_MODULE, szSetting, 0);
if (LOBYTE(HIWORD(cfg::dat.lastMsgFilter)))
cfg::dat.bFilterEffective |= CLVM_FILTER_LASTMSG_NEWERTHAN;
|