From 688f55ba998c19304a29727c910504903f4cc49a Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sun, 30 Nov 2014 18:51:36 +0000 Subject: lstr* replacements git-svn-id: http://svn.miranda-ng.org/main/trunk@11176 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/JabberG/src/ui_utils.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'protocols/JabberG/src/ui_utils.cpp') diff --git a/protocols/JabberG/src/ui_utils.cpp b/protocols/JabberG/src/ui_utils.cpp index 56db0d4827..696986e637 100644 --- a/protocols/JabberG/src/ui_utils.cpp +++ b/protocols/JabberG/src/ui_utils.cpp @@ -299,7 +299,7 @@ TCHAR* CCtrlCombo::GetItemText(int index, TCHAR *buf, int size) { TCHAR *result = (TCHAR *)_alloca(sizeof(TCHAR) * (SendMessage(m_hwnd, CB_GETLBTEXTLEN, index, 0) + 1)); SendMessage(m_hwnd, CB_GETLBTEXT, index, (LPARAM)result); - lstrcpyn(buf, result, size); + mir_tstrncpy(buf, result, size); return buf; } @@ -386,7 +386,7 @@ TCHAR* CCtrlListBox::GetItemText(int index, TCHAR *buf, int size) { TCHAR *result = (TCHAR *)_alloca(sizeof(TCHAR) * (SendMessage(m_hwnd, LB_GETTEXTLEN, index, 0) + 1)); SendMessage(m_hwnd, LB_GETTEXT, index, (LPARAM)result); - lstrcpyn(buf, result, size); + mir_tstrncpy(buf, result, size); return buf; } @@ -853,7 +853,7 @@ void CCtrlListView::AddGroup(int iGroupId, TCHAR *name) lvg.cbSize = sizeof(lvg); lvg.mask = LVGF_HEADER | LVGF_GROUPID; lvg.pszHeader = name; - lvg.cchHeader = lstrlen(lvg.pszHeader); + lvg.cchHeader = mir_tstrlen(lvg.pszHeader); lvg.iGroupId = iGroupId; InsertGroup(-1, &lvg); } @@ -2316,7 +2316,7 @@ void CProtoIntDlgBase::UpdateProtoTitle(const TCHAR *szText) if (szText) { curText = szText; - curLength = lstrlen(curText); + curLength = mir_tstrlen(curText); } else { curLength = GetWindowTextLength(m_hwnd) + 1; @@ -2326,7 +2326,7 @@ void CProtoIntDlgBase::UpdateProtoTitle(const TCHAR *szText) } if (!_tcsstr(curText, m_proto_interface->m_tszUserName)) { - int length = curLength + lstrlen(m_proto_interface->m_tszUserName) + 256; + int length = curLength + mir_tstrlen(m_proto_interface->m_tszUserName) + 256; TCHAR *text = (TCHAR *)_alloca(length * sizeof(TCHAR)); mir_sntprintf(text, length, _T("%s [%s: %s]"), curText, TranslateT("Account"), m_proto_interface->m_tszUserName); SetWindowText(m_hwnd, text); @@ -2339,7 +2339,7 @@ void CProtoIntDlgBase::UpdateStatusBar() HDC hdc = GetDC(m_hwndStatus); HFONT hFntSave = (HFONT)SelectObject(hdc, GetStockObject(DEFAULT_GUI_FONT)); - GetTextExtentPoint32(hdc, m_proto_interface->m_tszUserName, lstrlen(m_proto_interface->m_tszUserName), &sz); + GetTextExtentPoint32(hdc, m_proto_interface->m_tszUserName, mir_tstrlen(m_proto_interface->m_tszUserName), &sz); sz.cx += GetSystemMetrics(SM_CXSMICON) * 3; SelectObject(hdc, hFntSave); ReleaseDC(m_hwndStatus, hdc); -- cgit v1.2.3