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/Watrack_MPD/src/init.cpp | 2 +- plugins/Watrack_MPD/src/options.cpp | 10 +++++----- plugins/Watrack_MPD/src/stdafx.h | 2 +- plugins/Watrack_MPD/src/utilities.cpp | 4 ++-- plugins/Watrack_MPD/src/utilities.h | 2 +- 5 files changed, 10 insertions(+), 10 deletions(-) (limited to 'plugins/Watrack_MPD') diff --git a/plugins/Watrack_MPD/src/init.cpp b/plugins/Watrack_MPD/src/init.cpp index b93924c163..d5328df19b 100755 --- a/plugins/Watrack_MPD/src/init.cpp +++ b/plugins/Watrack_MPD/src/init.cpp @@ -19,7 +19,7 @@ HINSTANCE hInst; BOOL bWatrackService = FALSE; int hLangpack = 0; -TCHAR *gbHost, *gbPassword; +wchar_t *gbHost, *gbPassword; WORD gbPort; HANDLE ghNetlibUser; diff --git a/plugins/Watrack_MPD/src/options.cpp b/plugins/Watrack_MPD/src/options.cpp index 54d0c2d6ce..315c2f4100 100755 --- a/plugins/Watrack_MPD/src/options.cpp +++ b/plugins/Watrack_MPD/src/options.cpp @@ -24,7 +24,7 @@ static INT_PTR CALLBACK DlgProcWaMpdOpts(HWND hwndDlg, UINT msg, WPARAM, LPARAM { TranslateDialogDefault(hwndDlg); SetDlgItemInt(hwndDlg, IDC_PORT, db_get_w(NULL, szModuleName, "Port", 6600), FALSE); - TCHAR *tmp = UniGetContactSettingUtf(NULL, szModuleName, "Server", L"127.0.0.1"); + wchar_t *tmp = UniGetContactSettingUtf(NULL, szModuleName, "Server", L"127.0.0.1"); SetDlgItemText(hwndDlg, IDC_SERVER, tmp); mir_free(tmp); tmp = UniGetContactSettingUtf(NULL, szModuleName, "Password", L""); @@ -47,7 +47,7 @@ static INT_PTR CALLBACK DlgProcWaMpdOpts(HWND hwndDlg, UINT msg, WPARAM, LPARAM case PSN_APPLY: { - TCHAR szText[256]; + wchar_t szText[256]; db_set_w(NULL, szModuleName, "Port", (WORD)GetDlgItemInt(hwndDlg, IDC_PORT, NULL, FALSE)); gbPort = (WORD)GetDlgItemInt(hwndDlg, IDC_PORT, NULL, FALSE); GetDlgItemText(hwndDlg, IDC_SERVER, szText, _countof(szText)); @@ -71,9 +71,9 @@ int WaMpdOptInit(WPARAM wParam,LPARAM) OPTIONSDIALOGPAGE odp = { 0 }; odp.hInstance = hInst; odp.pszTemplate = MAKEINTRESOURCEA(IDD_OPT_WA_MPD); - odp.ptszTitle = LPGENT("Winamp Track"); - odp.ptszGroup = LPGENT("Plugins"); - odp.ptszTab = LPGENT("Watrack MPD"); + odp.pwszTitle = LPGENW("Winamp Track"); + odp.pwszGroup = LPGENW("Plugins"); + odp.pwszTab = LPGENW("Watrack MPD"); odp.flags=ODPF_BOLDGROUPS|ODPF_TCHAR; odp.pfnDlgProc = DlgProcWaMpdOpts; Options_AddPage(wParam, &odp); diff --git a/plugins/Watrack_MPD/src/stdafx.h b/plugins/Watrack_MPD/src/stdafx.h index ae1ef95c07..f339704541 100755 --- a/plugins/Watrack_MPD/src/stdafx.h +++ b/plugins/Watrack_MPD/src/stdafx.h @@ -36,7 +36,7 @@ extern HINSTANCE hInst; extern HANDLE ghNetlibUser; extern BOOL bWatrackService; -extern TCHAR *gbHost, *gbPassword; +extern wchar_t *gbHost, *gbPassword; extern WORD gbPort; extern char *date(); diff --git a/plugins/Watrack_MPD/src/utilities.cpp b/plugins/Watrack_MPD/src/utilities.cpp index 735c5f121a..edaf3f42bd 100755 --- a/plugins/Watrack_MPD/src/utilities.cpp +++ b/plugins/Watrack_MPD/src/utilities.cpp @@ -17,8 +17,8 @@ #include "stdafx.h" -TCHAR* __stdcall UniGetContactSettingUtf(MCONTACT hContact, const char *szModule,const char* szSetting, TCHAR* szDef) +wchar_t* __stdcall UniGetContactSettingUtf(MCONTACT hContact, const char *szModule,const char* szSetting, wchar_t* szDef) { - TCHAR *szRes = db_get_tsa(hContact, szModule, szSetting); + wchar_t *szRes = db_get_tsa(hContact, szModule, szSetting); return szRes ? szRes : mir_tstrdup(szDef); } diff --git a/plugins/Watrack_MPD/src/utilities.h b/plugins/Watrack_MPD/src/utilities.h index 39ee598973..3f594c7084 100755 --- a/plugins/Watrack_MPD/src/utilities.h +++ b/plugins/Watrack_MPD/src/utilities.h @@ -1,6 +1,6 @@ #ifndef UTILITIES_H #define UTILITIES_H -TCHAR* __stdcall UniGetContactSettingUtf(MCONTACT hContact, const char *szModule,const char* szSetting, TCHAR* szDef); +wchar_t* __stdcall UniGetContactSettingUtf(MCONTACT hContact, const char *szModule,const char* szSetting, wchar_t* szDef); #endif -- cgit v1.2.3