summaryrefslogtreecommitdiff
path: root/plugins/NewAwaySysMod
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2014-11-30 18:51:36 +0000
committerGeorge Hazan <george.hazan@gmail.com>2014-11-30 18:51:36 +0000
commit688f55ba998c19304a29727c910504903f4cc49a (patch)
tree69121ebb6d02bcf9e670428b11813087fc7f1640 /plugins/NewAwaySysMod
parent4f0e30cdf56fbafdf955bbe8b93930bab9e39bd0 (diff)
lstr* replacements
git-svn-id: http://svn.miranda-ng.org/main/trunk@11176 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/NewAwaySysMod')
-rw-r--r--plugins/NewAwaySysMod/src/CString.h8
-rw-r--r--plugins/NewAwaySysMod/src/GroupCheckbox.cpp4
-rw-r--r--plugins/NewAwaySysMod/src/Notification.cpp4
-rw-r--r--plugins/NewAwaySysMod/src/SetAwayMsg.cpp2
4 files changed, 9 insertions, 9 deletions
diff --git a/plugins/NewAwaySysMod/src/CString.h b/plugins/NewAwaySysMod/src/CString.h
index 0d81a4f7c3..161977cf28 100644
--- a/plugins/NewAwaySysMod/src/CString.h
+++ b/plugins/NewAwaySysMod/src/CString.h
@@ -29,14 +29,14 @@
#include "m_system.h"
#include "m_database.h"
-__inline int My_lstrlen(LPCSTR lpString) {return lstrlenA(lpString);}
-__inline int My_lstrlen(LPCWSTR lpString) {return lstrlenW(lpString);}
+__inline int My_lstrlen(LPCSTR lpString) {return mir_strlen(lpString);}
+__inline int My_lstrlen(LPCWSTR lpString) {return mir_wstrlen(lpString);}
__inline int My_lstrcmp(LPCSTR lpString1, LPCSTR lpString2) {return lstrcmpA(lpString1, lpString2);}
__inline int My_lstrcmp(LPCWSTR lpString1, LPCWSTR lpString2) {return lstrcmpW(lpString1, lpString2);}
__inline LPCSTR My_strstr(LPCSTR lpString1, LPCSTR lpString2) {return strstr(lpString1, lpString2);}
__inline LPWSTR My_strstr(LPCWSTR lpString1, LPCWSTR lpString2) {return (LPWSTR)wcsstr(lpString1, lpString2);}
-__inline LPSTR My_lstrcpy(LPSTR lpString1, LPCSTR lpString2) {return lstrcpyA(lpString1, lpString2);}
-__inline LPWSTR My_lstrcpy(LPWSTR lpString1, LPCWSTR lpString2) {return lstrcpyW(lpString1, lpString2);}
+__inline LPSTR My_lstrcpy(LPSTR lpString1, LPCSTR lpString2) {return mir_strcpy(lpString1, lpString2);}
+__inline LPWSTR My_lstrcpy(LPWSTR lpString1, LPCWSTR lpString2) {return mir_wstrcpy(lpString1, lpString2);}
__inline LPSTR My_strncpy(LPSTR lpString1, LPCSTR lpString2, int Len) {return strncpy(lpString1, lpString2, Len);}
__inline LPWSTR My_strncpy(LPWSTR lpString1, LPCWSTR lpString2, int Len) {return wcsncpy(lpString1, lpString2, Len);}
__inline LPSTR My_strlwr(LPSTR lpString) {return _strlwr(lpString);}
diff --git a/plugins/NewAwaySysMod/src/GroupCheckbox.cpp b/plugins/NewAwaySysMod/src/GroupCheckbox.cpp
index aca2c68830..040b566c94 100644
--- a/plugins/NewAwaySysMod/src/GroupCheckbox.cpp
+++ b/plugins/NewAwaySysMod/src/GroupCheckbox.cpp
@@ -97,7 +97,7 @@ static int CALLBACK CheckboxWndProc(HWND hWnd, UINT Msg, WPARAM wParam, LPARAM l
SIZE size;
TCHAR *szText = (TCHAR*)malloc(Len * sizeof(TCHAR));
GetWindowText(hWnd, szText, Len);
- GetTextExtentPoint32(hdc, szText, lstrlen(szText), &size);
+ GetTextExtentPoint32(hdc, szText, mir_tstrlen(szText), &size);
free(szText);
rcText.right = size.cx;
rcText.bottom = size.cy;
@@ -292,7 +292,7 @@ static int CALLBACK CheckboxWndProc(HWND hWnd, UINT Msg, WPARAM wParam, LPARAM l
GetThemeTextExtent(hTheme, hdcMem, BP_GROUPBOX, IsWindowEnabled(hWnd) ? GBS_NORMAL : GBS_DISABLED, szTextT, -1, DT_CALCRECT | DT_LEFT | DT_VCENTER | DT_SINGLELINE, 0, &rcText);
else {
SIZE size;
- GetTextExtentPoint32(hdcMem, szTextT, lstrlen(szTextT), &size);
+ GetTextExtentPoint32(hdcMem, szTextT, mir_tstrlen(szTextT), &size);
rcText.right = size.cx;
rcText.bottom = size.cy;
}
diff --git a/plugins/NewAwaySysMod/src/Notification.cpp b/plugins/NewAwaySysMod/src/Notification.cpp
index 258cdcfccc..6ef034d2f9 100644
--- a/plugins/NewAwaySysMod/src/Notification.cpp
+++ b/plugins/NewAwaySysMod/src/Notification.cpp
@@ -26,8 +26,8 @@ void ShowMsg(TCHAR *FirstLine, TCHAR *SecondLine, bool IsErrorMsg, int Timeout)
if (ServiceExists(MS_POPUP_ADDPOPUPT)) {
POPUPDATAT ppd = { 0 };
ppd.lchIcon = LoadIcon(NULL, IsErrorMsg ? IDI_EXCLAMATION : IDI_INFORMATION);
- lstrcpyn(ppd.lptzContactName, FirstLine, MAX_CONTACTNAME);
- lstrcpyn(ppd.lptzText, SecondLine, MAX_SECONDLINE);
+ mir_tstrncpy(ppd.lptzContactName, FirstLine, MAX_CONTACTNAME);
+ mir_tstrncpy(ppd.lptzText, SecondLine, MAX_SECONDLINE);
ppd.colorBack = IsErrorMsg ? 0x0202E3 : 0xE8F1FD;
ppd.colorText = IsErrorMsg ? 0xE8F1FD : 0x000000;
ppd.iSeconds = Timeout;
diff --git a/plugins/NewAwaySysMod/src/SetAwayMsg.cpp b/plugins/NewAwaySysMod/src/SetAwayMsg.cpp
index 12cd708ddc..8c6e7c8e43 100644
--- a/plugins/NewAwaySysMod/src/SetAwayMsg.cpp
+++ b/plugins/NewAwaySysMod/src/SetAwayMsg.cpp
@@ -369,7 +369,7 @@ void ApplySelContactsMessage(SetAwayMsgData* dat, CCList *CList, PTREEITEMARRAY
HWND hwndDlg = g_SetAwayMsgPage.GetWnd();
GetDlgItemText(hwndDlg, IDC_SAWAYMSG_MSGDATA, Message.GetBuffer(AWAY_MSGDATA_MAX), AWAY_MSGDATA_MAX);
Message.ReleaseBuffer();
- if (!lstrlen(Message))
+ if (!mir_tstrlen(Message))
Message = NULL; // delete personal message if it's empty
if (CList) {