summaryrefslogtreecommitdiff
path: root/src/modules/clist
diff options
context:
space:
mode:
authorKirill Volinsky <mataes2007@gmail.com>2015-04-28 08:14:32 +0000
committerKirill Volinsky <mataes2007@gmail.com>2015-04-28 08:14:32 +0000
commitb612f28362fe77f5a6cf8f8b75a0ac86167c7777 (patch)
tree42a40218246722d3391bed4e222623608ca9b6ad /src/modules/clist
parentceaff728d741c2c03378f63cb87480052fdc716f (diff)
minus ansi function
git-svn-id: http://svn.miranda-ng.org/main/trunk@13222 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'src/modules/clist')
-rw-r--r--src/modules/clist/clc.h2
-rw-r--r--src/modules/clist/clcutils.cpp16
2 files changed, 9 insertions, 9 deletions
diff --git a/src/modules/clist/clc.h b/src/modules/clist/clc.h
index c0100a6b8c..3a79db0804 100644
--- a/src/modules/clist/clc.h
+++ b/src/modules/clist/clc.h
@@ -71,7 +71,7 @@ void fnSaveStateAndRebuildList(HWND hwnd, struct ClcData *dat);
LRESULT fnProcessExternalMessages(HWND hwnd, struct ClcData *dat, UINT msg, WPARAM wParam, LPARAM lParam);
/* clcutils.c */
-char* fnGetGroupCountsText(struct ClcData *dat, ClcContact *contact);
+TCHAR* fnGetGroupCountsText(struct ClcData *dat, ClcContact *contact);
int fnHitTest(HWND hwnd, struct ClcData *dat, int testx, int testy, ClcContact **contact, ClcGroup **group, DWORD * flags);
void fnScrollTo(HWND hwnd, struct ClcData *dat, int desty, int noSmooth);
void fnEnsureVisible(HWND hwnd, struct ClcData *dat, int iItem, int partialOk);
diff --git a/src/modules/clist/clcutils.cpp b/src/modules/clist/clcutils.cpp
index b08c1a1c12..246c3ab893 100644
--- a/src/modules/clist/clcutils.cpp
+++ b/src/modules/clist/clcutils.cpp
@@ -29,10 +29,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
extern HANDLE hHideInfoTipEvent;
-char* fnGetGroupCountsText(struct ClcData *dat, ClcContact *contact)
+TCHAR* fnGetGroupCountsText(struct ClcData *dat, ClcContact *contact)
{
if (contact->type != CLCIT_GROUP || !(dat->exStyle & CLS_EX_SHOWGROUPCOUNTS))
- return "";
+ return _T("");
ClcGroup *group = contact->group, *topgroup = group;
int onlineCount = 0;
@@ -56,10 +56,10 @@ char* fnGetGroupCountsText(struct ClcData *dat, ClcContact *contact)
group->scanIndex++;
}
if (onlineCount == 0 && dat->exStyle & CLS_EX_HIDECOUNTSWHENEMPTY)
- return "";
+ return _T("");
- static char szName[32];
- mir_snprintf(szName, SIZEOF(szName), "(%u/%u)", onlineCount, totalCount);
+ static TCHAR szName[32];
+ mir_sntprintf(szName, SIZEOF(szName), _T("(%u/%u)"), onlineCount, totalCount);
return szName;
}
@@ -168,13 +168,13 @@ int fnHitTest(HWND hwnd, struct ClcData *dat, int testx, int testy, ClcContact *
GetTextExtentPoint32(hdc, hitcontact->szText, (int)mir_tstrlen(hitcontact->szText), &textSize);
int width = textSize.cx;
if (hitcontact->type == CLCIT_GROUP) {
- char *szCounts;
+ TCHAR *szCounts;
szCounts = cli.pfnGetGroupCountsText(dat, hitcontact);
if (szCounts[0]) {
- GetTextExtentPoint32A(hdc, " ", 1, &textSize);
+ GetTextExtentPoint32(hdc, _T(" "), 1, &textSize);
width += textSize.cx;
SelectObject(hdc, dat->fontInfo[FONTID_GROUPCOUNTS].hFont);
- GetTextExtentPoint32A(hdc, szCounts, (int)mir_strlen(szCounts), &textSize);
+ GetTextExtentPoint32(hdc, szCounts, (int)mir_tstrlen(szCounts), &textSize);
width += textSize.cx;
}
}