summaryrefslogtreecommitdiff
path: root/plugins/Variables
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2016-07-29 12:36:34 +0000
committerGeorge Hazan <george.hazan@gmail.com>2016-07-29 12:36:34 +0000
commit428bf0cbd77813a43094cb5c984436deff251936 (patch)
treed7dfa8971153d53a849e45c942be97fe5b90b7ec /plugins/Variables
parent82ef17ca5286f58ae7af604fb9518e8dc496b7c3 (diff)
no more TCHARs
git-svn-id: http://svn.miranda-ng.org/main/trunk@17143 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Variables')
-rw-r--r--plugins/Variables/src/contact.cpp6
-rw-r--r--plugins/Variables/src/dbhelpers.h2
-rw-r--r--plugins/Variables/src/help.cpp8
-rw-r--r--plugins/Variables/src/options.cpp4
-rw-r--r--plugins/Variables/src/parse_metacontacts.cpp6
-rw-r--r--plugins/Variables/src/parse_miranda.cpp10
-rw-r--r--plugins/Variables/src/variables.cpp2
7 files changed, 19 insertions, 19 deletions
diff --git a/plugins/Variables/src/contact.cpp b/plugins/Variables/src/contact.cpp
index b0a46021ee..471502da27 100644
--- a/plugins/Variables/src/contact.cpp
+++ b/plugins/Variables/src/contact.cpp
@@ -150,14 +150,14 @@ wchar_t* getContactInfoT(BYTE type, MCONTACT hContact)
return NULL;
case CCNF_GROUP:
- if ((res = db_get_tsa(hContact, "CList", "Group")) != NULL)
+ if ((res = db_get_wsa(hContact, "CList", "Group")) != NULL)
return res;
break;
case CNF_UNIQUEID:
//UID for ChatRoom
if (db_get_b(hContact, szProto, "ChatRoom", 0) == 1)
- if ((res = db_get_tsa(hContact, szProto, "ChatRoomID")) != NULL)
+ if ((res = db_get_wsa(hContact, szProto, "ChatRoomID")) != NULL)
return res;
//UID for other contact
@@ -192,7 +192,7 @@ MCONTACT getContactFromString(const wchar_t *tszContact, DWORD dwFlags, int nMat
}
// contact was not in cache, do a search
- CMString tmp;
+ CMStringW tmp;
int count = 0;
MCONTACT hContact;
LIST<void> arResults(1);
diff --git a/plugins/Variables/src/dbhelpers.h b/plugins/Variables/src/dbhelpers.h
index 4531bf397f..b942337774 100644
--- a/plugins/Variables/src/dbhelpers.h
+++ b/plugins/Variables/src/dbhelpers.h
@@ -104,7 +104,7 @@ static int __inline DBDeleteIthSetting(DWORD i, MCONTACT hContact,const char *sz
#define db_gets(a,b) db_get(NULL, MODULENAME, a, b)
#define db_setb(a,b) db_set_b(NULL, MODULENAME, a, (BYTE)(b))
#define db_sets(a,b) db_set_s(NULL, MODULENAME, a, b)
-#define db_setts(a,b) db_set_ts(NULL, MODULENAME, a, b)
+#define db_setts(a,b) db_set_ws(NULL, MODULENAME, a, b)
#define db_setw(a,b) db_set_w(NULL, MODULENAME, a, (WORD)(b))
#define db_setd(a,b) db_set_dw(NULL, MODULENAME, a, (DWORD)(b))
#define db_del(a) db_unset(NULL, MODULENAME, a);
diff --git a/plugins/Variables/src/help.cpp b/plugins/Variables/src/help.cpp
index 7d663d4aae..c32efb2dcb 100644
--- a/plugins/Variables/src/help.cpp
+++ b/plugins/Variables/src/help.cpp
@@ -129,7 +129,7 @@ static INT_PTR CALLBACK clistDlgProc(HWND hwndDlg,UINT msg,WPARAM wParam,LPARAM
MCONTACT hItem, hContact = wParam;
log_debugA("VARM_SETSUBJECT: %u", hContact);
if (hContact == INVALID_CONTACT_ID) {
- wchar_t *tszContact = db_get_tsa(NULL, MODULENAME, SETTING_SUBJECT);
+ wchar_t *tszContact = db_get_wsa(NULL, MODULENAME, SETTING_SUBJECT);
log_debugA("VARM_SETSUBJECT: %s", tszContact);
if (tszContact != NULL) {
hContact = getContactFromString(tszContact, CI_PROTOID);
@@ -204,7 +204,7 @@ static INT_PTR CALLBACK clistDlgProc(HWND hwndDlg,UINT msg,WPARAM wParam,LPARAM
if (hContact != NULL) {
wchar_t *tszContact = encodeContactToString(hContact);
if (tszContact != NULL) {
- db_set_ts(NULL, MODULENAME, SETTING_SUBJECT, tszContact);
+ db_set_ws(NULL, MODULENAME, SETTING_SUBJECT, tszContact);
mir_free(tszContact);
} }
break;
@@ -403,7 +403,7 @@ static BOOL CALLBACK processTokenListMessage(HWND hwndDlg, UINT msg, WPARAM, LPA
tszHelpDesc = mir_wstrdup(L"unknown");
lvItem.iSubItem = 1;
- lvItem.pszText = TranslateTS(tszHelpDesc);
+ lvItem.pszText = TranslateW(tszHelpDesc);
ListView_SetItem(hList, &lvItem);
mir_free(tszHelpDesc);
}
@@ -422,7 +422,7 @@ static BOOL CALLBACK processTokenListMessage(HWND hwndDlg, UINT msg, WPARAM, LPA
cat = getTokenCategory((TOKENREGISTEREX *)lvItem.lParam);
if (cat != NULL) {
- text = mir_wstrdup(TranslateTS(cat));
+ text = mir_wstrdup(TranslateW(cat));
mir_free(cat);
}
else text = NULL;
diff --git a/plugins/Variables/src/options.cpp b/plugins/Variables/src/options.cpp
index d07ad89999..8be86a9349 100644
--- a/plugins/Variables/src/options.cpp
+++ b/plugins/Variables/src/options.cpp
@@ -26,7 +26,7 @@ static INT_PTR CALLBACK SetOptsDlgProc(HWND hwndDlg,UINT msg,WPARAM wParam,LPARA
TranslateDialogDefault(hwndDlg);
{
DBVARIANT dbv;
- if (!db_get_ts( NULL, MODULENAME, SETTING_STARTUPTEXT, &dbv )) {
+ if (!db_get_ws( NULL, MODULENAME, SETTING_STARTUPTEXT, &dbv )) {
SetDlgItemText(hwndDlg, IDC_FORMATTEXT, dbv.ptszVal);
db_free(&dbv);
}
@@ -90,7 +90,7 @@ static INT_PTR CALLBACK SetOptsDlgProc(HWND hwndDlg,UINT msg,WPARAM wParam,LPARA
break;
if (GetDlgItemText(hwndDlg, IDC_FORMATTEXT, szFormatText, len+1) != 0)
- db_set_ts(NULL, MODULENAME, SETTING_STARTUPTEXT, szFormatText);
+ db_set_ws(NULL, MODULENAME, SETTING_STARTUPTEXT, szFormatText);
mir_free(szFormatText);
}
diff --git a/plugins/Variables/src/parse_metacontacts.cpp b/plugins/Variables/src/parse_metacontacts.cpp
index b8d2e9e324..9fc394c6f9 100644
--- a/plugins/Variables/src/parse_metacontacts.cpp
+++ b/plugins/Variables/src/parse_metacontacts.cpp
@@ -44,7 +44,7 @@ static wchar_t *parseGetParent(ARGUMENTSINFO *ai)
szUniqueID = mir_wstrdup(tszID);
}
- return CMString(FORMAT, L"<%S:%s>", szProto, szUniqueID).Detach();
+ return CMStringW(FORMAT, L"<%S:%s>", szProto, szUniqueID).Detach();
}
static wchar_t *parseGetDefault(ARGUMENTSINFO *ai)
@@ -72,7 +72,7 @@ static wchar_t *parseGetDefault(ARGUMENTSINFO *ai)
szUniqueID = mir_wstrdup(tszID);
}
- return CMString(FORMAT, L"<%S:%s>", szProto, szUniqueID).Detach();
+ return CMStringW(FORMAT, L"<%S:%s>", szProto, szUniqueID).Detach();
}
static wchar_t *parseGetMostOnline(ARGUMENTSINFO *ai)
@@ -100,7 +100,7 @@ static wchar_t *parseGetMostOnline(ARGUMENTSINFO *ai)
szUniqueID = mir_wstrdup(tszID);
}
- return CMString(FORMAT, L"<%S:%s>", szProto, szUniqueID).Detach();
+ return CMStringW(FORMAT, L"<%S:%s>", szProto, szUniqueID).Detach();
}
void registerMetaContactsTokens()
diff --git a/plugins/Variables/src/parse_miranda.cpp b/plugins/Variables/src/parse_miranda.cpp
index 11eb8d0181..72493df3da 100644
--- a/plugins/Variables/src/parse_miranda.cpp
+++ b/plugins/Variables/src/parse_miranda.cpp
@@ -126,7 +126,7 @@ static wchar_t* parseDBProfileName(ARGUMENTSINFO *ai)
return NULL;
wchar_t name[MAX_PATH];
- if (CallService(MS_DB_GETPROFILENAMET, _countof(name), (LPARAM)name))
+ if (CallService(MS_DB_GETPROFILENAMEW, _countof(name), (LPARAM)name))
return NULL;
return mir_wstrdup(name);
@@ -138,7 +138,7 @@ static wchar_t* parseDBProfilePath(ARGUMENTSINFO *ai)
return NULL;
wchar_t path[MAX_PATH];
- if (CallService(MS_DB_GETPROFILEPATHT, _countof(path), (LPARAM)path))
+ if (CallService(MS_DB_GETPROFILEPATHW, _countof(path), (LPARAM)path))
return NULL;
return mir_wstrdup(path);
@@ -395,7 +395,7 @@ static wchar_t* parseSpecialContact(ARGUMENTSINFO *ai)
if (szUniqueID == NULL)
return NULL;
- return CMString(FORMAT, L"<%S:%s>", szProto, szUniqueID).Detach();
+ return CMStringW(FORMAT, L"<%S:%s>", szProto, szUniqueID).Detach();
}
static BOOL isValidDbEvent(DBEVENTINFO *dbe, int flags)
@@ -579,7 +579,7 @@ static wchar_t* parseDbEvent(ARGUMENTSINFO *ai)
return NULL;
}
- wchar_t *res = DbGetEventTextT(&dbe, CP_ACP);
+ wchar_t *res = DbGetEventTextW(&dbe, CP_ACP);
mir_free(dbe.pBlob);
return res;
}
@@ -589,7 +589,7 @@ static wchar_t* parseTranslate(ARGUMENTSINFO *ai)
if (ai->argc != 2)
return NULL;
- wchar_t *res = TranslateTS(ai->targv[1]);
+ wchar_t *res = TranslateW(ai->targv[1]);
return (res == NULL) ? NULL : mir_wstrdup(res);
}
diff --git a/plugins/Variables/src/variables.cpp b/plugins/Variables/src/variables.cpp
index ace282aac9..a6db523926 100644
--- a/plugins/Variables/src/variables.cpp
+++ b/plugins/Variables/src/variables.cpp
@@ -455,7 +455,7 @@ int LoadVarModule()
if (db_get_b(NULL, MODULENAME, SETTING_PARSEATSTARTUP, 0)) {
FORMATINFO fi = { 0 };
fi.cbSize = sizeof(fi);
- fi.tszFormat = db_get_tsa(NULL, MODULENAME, SETTING_STARTUPTEXT);
+ fi.tszFormat = db_get_wsa(NULL, MODULENAME, SETTING_STARTUPTEXT);
if (fi.tszFormat != NULL) {
mir_free(formatString(&fi));
mir_free(fi.tszFormat);