diff options
Diffstat (limited to 'plugins/Clist_nicer/src/clcitems.cpp')
-rw-r--r-- | plugins/Clist_nicer/src/clcitems.cpp | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/plugins/Clist_nicer/src/clcitems.cpp b/plugins/Clist_nicer/src/clcitems.cpp index 8442edb661..94de708bef 100644 --- a/plugins/Clist_nicer/src/clcitems.cpp +++ b/plugins/Clist_nicer/src/clcitems.cpp @@ -225,7 +225,7 @@ BYTE GetCachedStatusMsg(TExtraCache *p, char *szProto) DBVARIANT dbv = {0};
INT_PTR result = cfg::getTString(hContact, "CList", "StatusMsg", &dbv);
- if ( !result && lstrlen(dbv.ptszVal) > 0)
+ if ( !result && mir_tstrlen(dbv.ptszVal) > 0)
p->bStatusMsgValid = STATUSMSG_CLIST;
else {
if ( !szProto)
@@ -233,11 +233,11 @@ BYTE GetCachedStatusMsg(TExtraCache *p, char *szProto) if (szProto) {
if ( !result )
db_free( &dbv );
- if ( !( result = cfg::getTString(hContact, szProto, "YMsg", &dbv)) && lstrlen(dbv.ptszVal) > 0)
+ if ( !( result = cfg::getTString(hContact, szProto, "YMsg", &dbv)) && mir_tstrlen(dbv.ptszVal) > 0)
p->bStatusMsgValid = STATUSMSG_YIM;
- else if ( !(result = cfg::getTString(hContact, szProto, "StatusDescr", &dbv)) && lstrlen(dbv.ptszVal) > 0)
+ else if ( !(result = cfg::getTString(hContact, szProto, "StatusDescr", &dbv)) && mir_tstrlen(dbv.ptszVal) > 0)
p->bStatusMsgValid = STATUSMSG_GG;
- else if ( !(result = cfg::getTString(hContact, szProto, "XStatusMsg", &dbv)) && lstrlen(dbv.ptszVal) > 0)
+ else if ( !(result = cfg::getTString(hContact, szProto, "XStatusMsg", &dbv)) && mir_tstrlen(dbv.ptszVal) > 0)
p->bStatusMsgValid = STATUSMSG_XSTATUS;
}
}
@@ -246,8 +246,8 @@ BYTE GetCachedStatusMsg(TExtraCache *p, char *szProto) if ( !result )
db_free( &dbv );
result = cfg::getTString(hContact, szProto, "XStatusName", &dbv);
- if ( !result && lstrlen(dbv.ptszVal) > 1) {
- int iLen = lstrlen(dbv.ptszVal);
+ if ( !result && mir_tstrlen(dbv.ptszVal) > 1) {
+ int iLen = mir_tstrlen(dbv.ptszVal);
p->bStatusMsgValid = STATUSMSG_XSTATUSNAME;
p->statusMsg = (TCHAR *)realloc(p->statusMsg, (iLen + 2) * sizeof(TCHAR));
_tcsncpy(p->statusMsg, dbv.ptszVal, iLen + 1);
@@ -266,8 +266,8 @@ BYTE GetCachedStatusMsg(TExtraCache *p, char *szProto) cst.ptszName = xStatusName;
if ( !CallProtoService(szProto, PS_GETCUSTOMSTATUSEX, hContact, (LPARAM)&cst)) {
TCHAR *szwXstatusName = TranslateTS(xStatusName);
- p->statusMsg = (TCHAR *)realloc(p->statusMsg, (lstrlen(szwXstatusName) + 2) * sizeof(TCHAR));
- _tcsncpy(p->statusMsg, szwXstatusName, lstrlen(szwXstatusName) + 1);
+ p->statusMsg = (TCHAR *)realloc(p->statusMsg, (mir_tstrlen(szwXstatusName) + 2) * sizeof(TCHAR));
+ _tcsncpy(p->statusMsg, szwXstatusName, mir_tstrlen(szwXstatusName) + 1);
p->bStatusMsgValid = STATUSMSG_XSTATUSNAME;
}
}
@@ -276,7 +276,7 @@ BYTE GetCachedStatusMsg(TExtraCache *p, char *szProto) if (p->bStatusMsgValid > STATUSMSG_XSTATUSNAME) {
int j = 0;
- p->statusMsg = (TCHAR *)realloc(p->statusMsg, (lstrlen(dbv.ptszVal) + 2) * sizeof(TCHAR));
+ p->statusMsg = (TCHAR *)realloc(p->statusMsg, (mir_tstrlen(dbv.ptszVal) + 2) * sizeof(TCHAR));
for (int i = 0; dbv.ptszVal[i]; i++) {
if (dbv.ptszVal[i] == (TCHAR)0x0d)
continue;
@@ -291,7 +291,7 @@ BYTE GetCachedStatusMsg(TExtraCache *p, char *szProto) if (p->bStatusMsgValid != STATUSMSG_NOTFOUND) {
WORD infoTypeC2[12];
ZeroMemory(infoTypeC2, sizeof(WORD) * 12);
- int iLen = min(lstrlenW(p->statusMsg), 10);
+ int iLen = min(mir_wstrlen(p->statusMsg), 10);
GetStringTypeW(CT_CTYPE2, p->statusMsg, iLen, infoTypeC2);
p->dwCFlags &= ~ECF_RTLSTATUSMSG;
for (int i = 0; i < 10; i++) {
@@ -361,7 +361,7 @@ void RTL_DetectAndSet(ClcContact *contact, MCONTACT hContact) p = contact->pExtra;
}
if (p) {
- iLen = min(lstrlenW(szText), 10);
+ iLen = min(mir_wstrlen(szText), 10);
GetStringTypeW(CT_CTYPE2, szText, iLen, infoTypeC2);
p->dwCFlags &= ~ECF_RTLNICK;
for (i = 0; i < 10; i++) {
@@ -382,7 +382,7 @@ void RTL_DetectGroupName(ClcContact *group) group->isRtl = 0;
if (group->szText) {
- iLen = min(lstrlenW(group->szText), 10);
+ iLen = min(mir_wstrlen(group->szText), 10);
GetStringTypeW(CT_CTYPE2, group->szText, iLen, infoTypeC2);
for (i = 0; i < 10; i++) {
if (infoTypeC2[i] == C2_RIGHTTOLEFT) {
|