From 6e53dfca72b932c4bdcd7aa02ca62bf8b2630eac Mon Sep 17 00:00:00 2001 From: George Hazan Date: Tue, 26 Jul 2016 09:20:25 +0000 Subject: less TCHARs: - TCHAR is replaced with wchar_t everywhere; - LPGENT replaced with either LPGENW or LPGEN; - fixes for ANSI plugins that improperly used _t functions; - TCHAR *t removed from MAllStrings; - ptszGroup, ptszTitle & ptszTab in OPTIONSDIALOGPAGE replaced with pwsz* git-svn-id: http://svn.miranda-ng.org/main/trunk@17133 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/WhenWasIt/src/utils.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'plugins/WhenWasIt/src/utils.cpp') diff --git a/plugins/WhenWasIt/src/utils.cpp b/plugins/WhenWasIt/src/utils.cpp index 9667b1bc37..6c0c253a12 100644 --- a/plugins/WhenWasIt/src/utils.cpp +++ b/plugins/WhenWasIt/src/utils.cpp @@ -138,22 +138,22 @@ int GetStringFromDatabase(char *szSettingName, char *szError, char *szResult, si return GetStringFromDatabase(NULL, ModuleName, szSettingName, szError, szResult, size); } -TCHAR* GetContactID(MCONTACT hContact) +wchar_t* GetContactID(MCONTACT hContact) { return GetContactID(hContact, NULL); } -TCHAR* GetContactID(MCONTACT hContact, char *szProto) +wchar_t* GetContactID(MCONTACT hContact, char *szProto) { ptrT res(Contact_GetInfo(CNF_UNIQUEID, hContact, szProto)); - return (res) ? _tcsdup(res) : NULL; + return (res) ? wcsdup(res) : NULL; } -MCONTACT GetContactFromID(TCHAR *szID, char *szProto) +MCONTACT GetContactFromID(wchar_t *szID, char *szProto) { for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) { char *m_szProto = GetContactProto(hContact); - TCHAR *szHandle = GetContactID(hContact, szProto); + wchar_t *szHandle = GetContactID(hContact, szProto); if (szHandle) { bool found = (!mir_tstrcmpi(szHandle, szID) && !_stricmp(szProto, m_szProto)); free(szHandle); @@ -164,7 +164,7 @@ MCONTACT GetContactFromID(TCHAR *szID, char *szProto) return NULL; } -MCONTACT GetContactFromID(TCHAR *szID, wchar_t *szProto) +MCONTACT GetContactFromID(wchar_t *szID, wchar_t *szProto) { char protocol[1024]; WideCharToMultiByte(CP_ACP, 0, szProto, -1, protocol, sizeof(protocol), NULL, NULL); -- cgit v1.2.3