summaryrefslogtreecommitdiff
path: root/plugins/TrafficCounter/src/misc.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2016-07-25 10:31:04 +0000
committerGeorge Hazan <george.hazan@gmail.com>2016-07-25 10:31:04 +0000
commit8ae3679aa1339ce9abee53adb69902bd6b7513dc (patch)
tree94ef8927e12043ed6dcc15e1e640d68a8add520e /plugins/TrafficCounter/src/misc.cpp
parent1e273e28d89b5838e3d0f0cafac9676577cb71ce (diff)
hello, Unix.
phase 1: removing _T() git-svn-id: http://svn.miranda-ng.org/main/trunk@17127 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/TrafficCounter/src/misc.cpp')
-rw-r--r--plugins/TrafficCounter/src/misc.cpp34
1 files changed, 17 insertions, 17 deletions
diff --git a/plugins/TrafficCounter/src/misc.cpp b/plugins/TrafficCounter/src/misc.cpp
index ef54ae6ed1..5c23fd4541 100644
--- a/plugins/TrafficCounter/src/misc.cpp
+++ b/plugins/TrafficCounter/src/misc.cpp
@@ -47,7 +47,7 @@ WORD GetRowItems(TCHAR *InputString, RowItemInfo **RowItemsList)
*RowItemsList = (RowItemInfo*)mir_realloc(*RowItemsList, sizeof(RowItemInfo) * (c + 1));
// Разбираем тег.
- _stscanf(begin + 1, _T("%c%hd"),
+ _stscanf(begin + 1, L"%c%hd",
&((*RowItemsList)[c].Alignment),
&((*RowItemsList)[c].Interval));
@@ -122,7 +122,7 @@ size_t GetFormattedTraffic(DWORD Value, BYTE Unit, TCHAR *Buffer, size_t Size)
{
TCHAR Str1[32], szUnit[4] = { ' ', 0 };
DWORD Divider;
- NUMBERFMT nf = { 0, 1, 3, _T(","), _T(" "), 0 };
+ NUMBERFMT nf = { 0, 1, 3, L",", L" ", 0 };
TCHAR *Res; // Промежуточный результат.
switch (Unit) {
@@ -148,7 +148,7 @@ size_t GetFormattedTraffic(DWORD Value, BYTE Unit, TCHAR *Buffer, size_t Size)
return 0;
}
- mir_sntprintf(Str1, _T("%d.%d"), Value / Divider, Value % Divider);
+ mir_sntprintf(Str1, L"%d.%d", Value / Divider, Value % Divider);
size_t l = GetNumberFormat(LOCALE_USER_DEFAULT, 0, Str1, &nf, NULL, 0);
if (!l) return 0;
l += mir_tstrlen(szUnit) + 1;
@@ -197,39 +197,39 @@ size_t GetDurationFormatM(DWORD Duration, TCHAR *Format, TCHAR *Buffer, size_t S
Token[TokenIndex] = 0;
// Что получили в аккумуляторе?
- if (!mir_tstrcmp(Token, _T("d"))) {
+ if (!mir_tstrcmp(Token, L"d")) {
q = Duration / (60 * 60 * 24);
- mir_sntprintf(Token, _T("%d"), q);
+ mir_sntprintf(Token, L"%d", q);
Duration -= q * 60 * 60 * 24;
}
- else if (!mir_tstrcmp(Token, _T("h"))) {
+ else if (!mir_tstrcmp(Token, L"h")) {
q = Duration / (60 * 60);
- mir_sntprintf(Token, _T("%d"), q);
+ mir_sntprintf(Token, L"%d", q);
Duration -= q * 60 * 60;
}
- else if (!mir_tstrcmp(Token, _T("hh"))) {
+ else if (!mir_tstrcmp(Token, L"hh")) {
q = Duration / (60 * 60);
- mir_sntprintf(Token, _T("%02d"), q);
+ mir_sntprintf(Token, L"%02d", q);
Duration -= q * 60 * 60;
}
- else if (!mir_tstrcmp(Token, _T("m"))) {
+ else if (!mir_tstrcmp(Token, L"m")) {
q = Duration / 60;
- mir_sntprintf(Token, _T("%d"), q);
+ mir_sntprintf(Token, L"%d", q);
Duration -= q * 60;
}
- else if (!mir_tstrcmp(Token, _T("mm"))) {
+ else if (!mir_tstrcmp(Token, L"mm")) {
q = Duration / 60;
- mir_sntprintf(Token, _T("%02d"), q);
+ mir_sntprintf(Token, L"%02d", q);
Duration -= q * 60;
}
- else if (!mir_tstrcmp(Token, _T("s"))) {
+ else if (!mir_tstrcmp(Token, L"s")) {
q = Duration;
- mir_sntprintf(Token, _T("%d"), q);
+ mir_sntprintf(Token, L"%d", q);
Duration -= q;
}
- else if (!mir_tstrcmp(Token, _T("ss"))) {
+ else if (!mir_tstrcmp(Token, L"ss")) {
q = Duration;
- mir_sntprintf(Token, _T("%02d"), q);
+ mir_sntprintf(Token, L"%02d", q);
Duration -= q;
}