summaryrefslogtreecommitdiff
path: root/plugins/Variables/src/parse_logic.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2016-07-27 14:23:31 +0000
committerGeorge Hazan <george.hazan@gmail.com>2016-07-27 14:23:31 +0000
commit2f261839b60692e33d0e160344d0d636d49c90ba (patch)
tree187921722698b681d29df3f6e60fb18394a5e9d5 /plugins/Variables/src/parse_logic.cpp
parent2e931a0b2780587d85f3902468c935f5adba70c8 (diff)
less TCHARs
git-svn-id: http://svn.miranda-ng.org/main/trunk@17138 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Variables/src/parse_logic.cpp')
-rw-r--r--plugins/Variables/src/parse_logic.cpp60
1 files changed, 30 insertions, 30 deletions
diff --git a/plugins/Variables/src/parse_logic.cpp b/plugins/Variables/src/parse_logic.cpp
index 763136f821..0737a17d11 100644
--- a/plugins/Variables/src/parse_logic.cpp
+++ b/plugins/Variables/src/parse_logic.cpp
@@ -32,11 +32,11 @@ static wchar_t *parseAnd(ARGUMENTSINFO *ai)
if (fi.eCount > 0) {
ai->flags |= AIF_FALSE;
- return mir_tstrdup(L"");
+ return mir_wstrdup(L"");
}
}
- return mir_tstrdup(L"");
+ return mir_wstrdup(L"");
}
static wchar_t *parseFalse(ARGUMENTSINFO *ai)
@@ -45,7 +45,7 @@ static wchar_t *parseFalse(ARGUMENTSINFO *ai)
return NULL;
ai->flags |= AIF_FALSE;
- return mir_tstrdup(L"");
+ return mir_wstrdup(L"");
}
static wchar_t *parseIf(ARGUMENTSINFO *ai)
@@ -59,7 +59,7 @@ static wchar_t *parseIf(ARGUMENTSINFO *ai)
fi.tszFormat = ai->targv[1];
mir_free(formatString(&fi));
- return mir_tstrdup((fi.eCount == 0) ? ai->targv[2] : ai->targv[3]);
+ return mir_wstrdup((fi.eCount == 0) ? ai->targv[2] : ai->targv[3]);
}
static wchar_t *parseIf2(ARGUMENTSINFO *ai)
@@ -76,7 +76,7 @@ static wchar_t *parseIf2(ARGUMENTSINFO *ai)
return szCondition;
mir_free(szCondition);
- return mir_tstrdup(ai->targv[2]);
+ return mir_wstrdup(ai->targv[2]);
}
static wchar_t *parseIf3(ARGUMENTSINFO *ai)
@@ -104,16 +104,16 @@ static wchar_t *parseIfequal(ARGUMENTSINFO *ai)
FORMATINFO fi;
memcpy(&fi, ai->fi, sizeof(fi));
fi.szFormat = ai->argv[1];
- ptrT tszFirst(formatString(&fi));
+ ptrW tszFirst(formatString(&fi));
fi.szFormat = ai->argv[2];
- ptrT tszSecond(formatString(&fi));
+ ptrW tszSecond(formatString(&fi));
if (tszFirst == NULL || tszSecond == NULL)
return NULL;
if (ttoi(tszFirst) == ttoi(tszSecond))
- return mir_tstrdup(ai->targv[3]);
+ return mir_wstrdup(ai->targv[3]);
- return mir_tstrdup(ai->targv[4]);
+ return mir_wstrdup(ai->targv[4]);
}
static wchar_t *parseIfgreater(ARGUMENTSINFO *ai)
@@ -124,16 +124,16 @@ static wchar_t *parseIfgreater(ARGUMENTSINFO *ai)
FORMATINFO fi;
memcpy(&fi, ai->fi, sizeof(fi));
fi.szFormat = ai->argv[1];
- ptrT tszFirst(formatString(&fi));
+ ptrW tszFirst(formatString(&fi));
fi.szFormat = ai->argv[2];
- ptrT tszSecond(formatString(&fi));
+ ptrW tszSecond(formatString(&fi));
if (tszFirst == NULL || tszSecond == NULL)
return NULL;
if (ttoi(tszFirst) > ttoi(tszSecond))
- return mir_tstrdup(ai->targv[3]);
+ return mir_wstrdup(ai->targv[3]);
- return mir_tstrdup(ai->targv[4]);
+ return mir_wstrdup(ai->targv[4]);
}
static wchar_t *parseIflonger(ARGUMENTSINFO *ai)
@@ -144,16 +144,16 @@ static wchar_t *parseIflonger(ARGUMENTSINFO *ai)
FORMATINFO fi;
memcpy(&fi, ai->fi, sizeof(fi));
fi.szFormat = ai->argv[1];
- ptrT tszFirst(formatString(&fi));
+ ptrW tszFirst(formatString(&fi));
fi.szFormat = ai->argv[2];
- ptrT tszSecond(formatString(&fi));
+ ptrW tszSecond(formatString(&fi));
if (tszFirst == NULL || tszSecond == NULL)
return NULL;
- if (mir_tstrlen(tszFirst) > mir_tstrlen(tszSecond))
- return mir_tstrdup(ai->targv[3]);
+ if (mir_wstrlen(tszFirst) > mir_wstrlen(tszSecond))
+ return mir_wstrdup(ai->targv[3]);
- return mir_tstrdup(ai->targv[4]);
+ return mir_wstrdup(ai->targv[4]);
}
/*
@@ -166,7 +166,7 @@ static wchar_t *parseFor(ARGUMENTSINFO *ai)
if (ai->argc != 5)
return NULL;
- wchar_t *res = mir_tstrdup(L"");
+ wchar_t *res = mir_wstrdup(L"");
FORMATINFO fi;
memcpy(&fi, ai->fi, sizeof(fi));
@@ -180,15 +180,15 @@ static wchar_t *parseFor(ARGUMENTSINFO *ai)
wchar_t *parsed = formatString(&fi);
if (parsed != NULL) {
if (res == NULL) {
- res = (wchar_t*)mir_alloc(mir_tstrlen(parsed) + 1 * sizeof(wchar_t));
+ res = (wchar_t*)mir_alloc(mir_wstrlen(parsed) + 1 * sizeof(wchar_t));
if (res == NULL) {
mir_free(parsed);
return NULL;
}
}
- else res = (wchar_t*)mir_realloc(res, (mir_tstrlen(res) + mir_tstrlen(parsed) + 1)*sizeof(wchar_t));
+ else res = (wchar_t*)mir_realloc(res, (mir_wstrlen(res) + mir_wstrlen(parsed) + 1)*sizeof(wchar_t));
- mir_tstrcat(res, parsed);
+ mir_wstrcat(res, parsed);
mir_free(parsed);
}
fi.tszFormat = ai->targv[3];
@@ -209,7 +209,7 @@ static wchar_t *parseEqual(ARGUMENTSINFO *ai)
if (ttoi(ai->targv[1]) != ttoi(ai->targv[2]))
ai->flags |= AIF_FALSE;
- return mir_tstrdup(L"");
+ return mir_wstrdup(L"");
}
static wchar_t *parseGreater(ARGUMENTSINFO *ai)
@@ -220,7 +220,7 @@ static wchar_t *parseGreater(ARGUMENTSINFO *ai)
if (ttoi(ai->targv[1]) <= ttoi(ai->targv[2]))
ai->flags |= AIF_FALSE;
- return mir_tstrdup(L"");
+ return mir_wstrdup(L"");
}
static wchar_t *parseLonger(ARGUMENTSINFO *ai)
@@ -228,10 +228,10 @@ static wchar_t *parseLonger(ARGUMENTSINFO *ai)
if (ai->argc != 3)
return NULL;
- if (mir_tstrlen(ai->targv[1]) <= mir_tstrlen(ai->targv[2]))
+ if (mir_wstrlen(ai->targv[1]) <= mir_wstrlen(ai->targv[2]))
ai->flags |= AIF_FALSE;
- return mir_tstrdup(L"");
+ return mir_wstrdup(L"");
}
static wchar_t *parseNot(ARGUMENTSINFO *ai)
@@ -248,7 +248,7 @@ static wchar_t *parseNot(ARGUMENTSINFO *ai)
if (fi.eCount == 0)
ai->flags |= AIF_FALSE;
- return mir_tstrdup(L"");
+ return mir_wstrdup(L"");
}
static wchar_t *parseOr(ARGUMENTSINFO *ai)
@@ -268,12 +268,12 @@ static wchar_t *parseOr(ARGUMENTSINFO *ai)
ai->flags &= ~AIF_FALSE;
}
- return mir_tstrdup(L"");
+ return mir_wstrdup(L"");
}
static wchar_t *parseTrue(ARGUMENTSINFO *ai)
{
- return (ai->argc != 1) ? NULL : mir_tstrdup(L"");
+ return (ai->argc != 1) ? NULL : mir_wstrdup(L"");
}
static wchar_t *parseXor(ARGUMENTSINFO *ai)
@@ -293,7 +293,7 @@ static wchar_t *parseXor(ARGUMENTSINFO *ai)
int val2 = fi.eCount == 0;
ai->flags |= ((val1 & AIF_FALSE) == !(val2 & AIF_FALSE)) ? 0 : AIF_FALSE;
- return mir_tstrdup(L"");
+ return mir_wstrdup(L"");
}
void registerLogicTokens()