diff options
Diffstat (limited to 'plugins/Scriver')
-rw-r--r-- | plugins/Scriver/src/chat/options.cpp | 10 | ||||
-rw-r--r-- | plugins/Scriver/src/chat/tools.cpp | 2 | ||||
-rw-r--r-- | plugins/Scriver/src/chat/window.cpp | 4 | ||||
-rw-r--r-- | plugins/Scriver/src/infobar.cpp | 10 | ||||
-rw-r--r-- | plugins/Scriver/src/msgdialog.cpp | 6 | ||||
-rw-r--r-- | plugins/Scriver/src/msglog.cpp | 2 | ||||
-rw-r--r-- | plugins/Scriver/src/msgoptions.cpp | 12 | ||||
-rw-r--r-- | plugins/Scriver/src/msgwindow.cpp | 6 |
8 files changed, 26 insertions, 26 deletions
diff --git a/plugins/Scriver/src/chat/options.cpp b/plugins/Scriver/src/chat/options.cpp index 985077fde9..4063da39ae 100644 --- a/plugins/Scriver/src/chat/options.cpp +++ b/plugins/Scriver/src/chat/options.cpp @@ -113,7 +113,7 @@ static HTREEITEM InsertBranch(HWND hwndTree, wchar_t* pszDescr, BOOL bExpanded) tvis.hParent = NULL;
tvis.hInsertAfter = TVI_LAST;
tvis.item.mask = TVIF_TEXT | TVIF_STATE;
- tvis.item.pszText = TranslateTS(pszDescr);
+ tvis.item.pszText = TranslateW(pszDescr);
tvis.item.stateMask = bExpanded ? TVIS_STATEIMAGEMASK | TVIS_EXPANDED : TVIS_STATEIMAGEMASK;
tvis.item.state = bExpanded ? INDEXTOSTATEIMAGEMASK(1) | TVIS_EXPANDED : INDEXTOSTATEIMAGEMASK(1);
return TreeView_InsertItem(hwndTree, &tvis);
@@ -128,7 +128,7 @@ static void FillBranch(HWND hwndTree, HTREEITEM hParent, struct branch_t *branch tvis.hInsertAfter = TVI_LAST;
tvis.item.mask = TVIF_TEXT | TVIF_STATE;
for (int i = 0; i < nValues; i++) {
- tvis.item.pszText = TranslateTS(branch[i].szDescr);
+ tvis.item.pszText = TranslateW(branch[i].szDescr);
tvis.item.stateMask = TVIS_STATEIMAGEMASK;
if (branch[i].iMode)
iState = ((db_get_dw(NULL, CHAT_MODULE, branch[i].szDBName, defaultval)&branch[i].iMode)&branch[i].iMode) != 0 ? 2 : 1;
@@ -225,7 +225,7 @@ static INT CALLBACK BrowseCallbackProc(HWND hwnd, UINT uMsg, LPARAM lp, LPARAM p static void InitSetting(wchar_t **ppPointer, char *pszSetting, wchar_t *pszDefault)
{
DBVARIANT dbv;
- if ( !db_get_ts(NULL, CHAT_MODULE, pszSetting, &dbv )) {
+ if ( !db_get_ws(NULL, CHAT_MODULE, pszSetting, &dbv )) {
replaceStrW(*ppPointer, dbv.ptszVal);
db_free(&dbv);
}
@@ -529,7 +529,7 @@ INT_PTR CALLBACK DlgProcOptions2(HWND hwndDlg,UINT uMsg,WPARAM wParam,LPARAM lPa *p2 = ' ';
p2 = wcschr(ptszText, (wchar_t)',');
}
- db_set_ts(NULL, CHAT_MODULE, "HighlightWords", ptszText);
+ db_set_ws(NULL, CHAT_MODULE, "HighlightWords", ptszText);
mir_free(ptszText);
}
}
@@ -539,7 +539,7 @@ INT_PTR CALLBACK DlgProcOptions2(HWND hwndDlg,UINT uMsg,WPARAM wParam,LPARAM lPa if (iLen > 0) {
wchar_t *pszText1 = (wchar_t*)malloc(iLen*sizeof(wchar_t)+2);
GetDlgItemText(hwndDlg, IDC_CHAT_LOGDIRECTORY, pszText1, iLen + 1);
- db_set_ts(NULL, CHAT_MODULE, "LogDirectory", pszText1);
+ db_set_ws(NULL, CHAT_MODULE, "LogDirectory", pszText1);
free(pszText1);
}
else {
diff --git a/plugins/Scriver/src/chat/tools.cpp b/plugins/Scriver/src/chat/tools.cpp index 3b9c78291c..7b002430ff 100644 --- a/plugins/Scriver/src/chat/tools.cpp +++ b/plugins/Scriver/src/chat/tools.cpp @@ -79,7 +79,7 @@ UINT CreateGCMenu(HWND hwnd, HMENU *hMenu, int iIndex, POINT pt, SESSION_INFO *s AppendMenu(*hMenu, MF_SEPARATOR, 0, 0);
for (int i = 0; i < gcmi.nItems; i++) {
- wchar_t *ptszText = TranslateTS(gcmi.Item[i].pszDesc);
+ wchar_t *ptszText = TranslateW(gcmi.Item[i].pszDesc);
DWORD dwState = gcmi.Item[i].bDisabled ? MF_GRAYED : 0;
if (gcmi.Item[i].uType == MENU_NEWPOPUP) {
diff --git a/plugins/Scriver/src/chat/window.cpp b/plugins/Scriver/src/chat/window.cpp index 0be7880de0..565a5f8111 100644 --- a/plugins/Scriver/src/chat/window.cpp +++ b/plugins/Scriver/src/chat/window.cpp @@ -1706,7 +1706,7 @@ LABEL_SHOWWINDOW: // takes pszRtf to a queue, no leak here
si->cmdList = tcmdlist_append(si->cmdList, pszRtf, 20, FALSE);
- CMString ptszText(ptrW(mir_utf8decodeW(pszRtf)));
+ CMStringW ptszText(ptrW(mir_utf8decodeW(pszRtf)));
pci->DoRtfToTags(ptszText, mi->nColorCount, mi->crColors);
ptszText.Trim();
ptszText.Replace(L"%", L"%%");
@@ -1907,7 +1907,7 @@ LABEL_SHOWWINDOW: mii.wID = i + 1;
mii.dwItemData = (ULONG_PTR)g_dat.hChatButtonIconList;
mii.hbmpItem = HBMMENU_CALLBACK;
- mii.dwTypeData = TranslateTS((toolbarButtons[i].name));
+ mii.dwTypeData = TranslateW((toolbarButtons[i].name));
InsertMenuItem(hToolbarMenu, i, TRUE, &mii);
}
diff --git a/plugins/Scriver/src/infobar.cpp b/plugins/Scriver/src/infobar.cpp index 8ff69e1288..764bbdd844 100644 --- a/plugins/Scriver/src/infobar.cpp +++ b/plugins/Scriver/src/infobar.cpp @@ -79,16 +79,16 @@ void RefreshInfobar(InfobarWindowData* idat) {
HWND hwnd = idat->hWnd;
SrmmWindowData *dat = idat->mwd;
- ptrW szContactStatusMsg(db_get_tsa(dat->hContact, "CList", "StatusMsg"));
- ptrW szXStatusName(db_get_tsa(idat->mwd->hContact, idat->mwd->szProto, "XStatusName"));
- ptrW szXStatusMsg(db_get_tsa(idat->mwd->hContact, idat->mwd->szProto, "XStatusMsg"));
+ ptrW szContactStatusMsg(db_get_wsa(dat->hContact, "CList", "StatusMsg"));
+ ptrW szXStatusName(db_get_wsa(idat->mwd->hContact, idat->mwd->szProto, "XStatusName"));
+ ptrW szXStatusMsg(db_get_wsa(idat->mwd->hContact, idat->mwd->szProto, "XStatusMsg"));
HICON hIcon = GetExtraStatusIcon(idat);
wchar_t szText[2048];
SETTEXTEX st;
if (szXStatusMsg && *szXStatusMsg)
- mir_snwprintf(szText, L"%s (%s)", TranslateTS(szXStatusName), szXStatusMsg);
+ mir_snwprintf(szText, L"%s (%s)", TranslateW(szXStatusName), szXStatusMsg);
else
- wcsncpy_s(szText, TranslateTS(szXStatusName), _TRUNCATE);
+ wcsncpy_s(szText, TranslateW(szXStatusName), _TRUNCATE);
st.flags = ST_DEFAULT;
st.codepage = 1200;
SendDlgItemMessage(hwnd, IDC_INFOBAR_NAME, EM_SETTEXTEX, (WPARAM)&st, (LPARAM)pcli->pfnGetContactDisplayName(dat->hContact, 0));
diff --git a/plugins/Scriver/src/msgdialog.cpp b/plugins/Scriver/src/msgdialog.cpp index 5aab926147..e1ddf07e4e 100644 --- a/plugins/Scriver/src/msgdialog.cpp +++ b/plugins/Scriver/src/msgdialog.cpp @@ -759,7 +759,7 @@ INT_PTR CALLBACK DlgProcMessage(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lP SetDlgItemTextA(hwndDlg, IDC_MESSAGE, newData->szInitialText);
}
else if (g_dat.flags & SMF_SAVEDRAFTS) {
- ptrW ptszSavedMsg(db_get_tsa(dat->hContact, "SRMM", "SavedMsg"));
+ ptrW ptszSavedMsg(db_get_wsa(dat->hContact, "SRMM", "SavedMsg"));
if (ptszSavedMsg)
len = SetRichText(GetDlgItem(hwndDlg, IDC_MESSAGE), ptszSavedMsg);
PostMessage(GetDlgItem(hwndDlg, IDC_MESSAGE), EM_SETSEL, len, len);
@@ -931,7 +931,7 @@ INT_PTR CALLBACK DlgProcMessage(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lP mii.wID = i + 1;
mii.dwItemData = (ULONG_PTR)g_dat.hButtonIconList;
mii.hbmpItem = HBMMENU_CALLBACK;
- mii.dwTypeData = TranslateTS((toolbarButtons[i].name));
+ mii.dwTypeData = TranslateW((toolbarButtons[i].name));
InsertMenuItem(hToolbarMenu, i, TRUE, &mii);
}
{
@@ -1670,7 +1670,7 @@ INT_PTR CALLBACK DlgProcMessage(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lP dbei.pBlob = (PBYTE)mir_alloc(dbei.cbBlob);
db_event_get(dat->hDbEventLast, &dbei);
if (DbEventIsMessageOrCustom(&dbei)) {
- buffer = DbGetEventTextT(&dbei, CP_ACP);
+ buffer = DbGetEventTextW(&dbei, CP_ACP);
if (buffer != NULL) {
wchar_t *quotedBuffer = GetQuotedTextW(buffer);
SendDlgItemMessage(hwndDlg, IDC_MESSAGE, EM_SETTEXTEX, (WPARAM)&st, (LPARAM)quotedBuffer);
diff --git a/plugins/Scriver/src/msglog.cpp b/plugins/Scriver/src/msglog.cpp index f75057670b..b890d7f12b 100644 --- a/plugins/Scriver/src/msglog.cpp +++ b/plugins/Scriver/src/msglog.cpp @@ -156,7 +156,7 @@ EventData* getEventFromDB(SrmmWindowData *dat, MCONTACT hContact, MEVENT hDbEven if (*descr != 0)
evt->pszText2T = DbGetEventStringT(&dbei, descr);
}
- else evt->pszTextT = DbGetEventTextT(&dbei, CP_UTF8);
+ else evt->pszTextT = DbGetEventTextW(&dbei, CP_UTF8);
if (!(dat->flags & SMF_RTL) && RTL_Detect(evt->pszTextT))
evt->dwFlags |= IEEDF_RTL;
diff --git a/plugins/Scriver/src/msgoptions.cpp b/plugins/Scriver/src/msgoptions.cpp index 6685fdc099..98198af1a6 100644 --- a/plugins/Scriver/src/msgoptions.cpp +++ b/plugins/Scriver/src/msgoptions.cpp @@ -105,7 +105,7 @@ int FontServiceFontsChanged(WPARAM, LPARAM) void RegisterFontServiceFonts()
{
- FontIDT fid = { sizeof(fid) };
+ FontIDW fid = { sizeof(fid) };
wcsncpy_s(fid.group, LPGENW("Messaging"), _TRUNCATE);
wcsncpy_s(fid.backgroundGroup, LPGENW("Messaging"), _TRUNCATE);
strncpy(fid.dbSettingsGroup, SRMMMOD, _countof(fid.dbSettingsGroup));
@@ -123,10 +123,10 @@ void RegisterFontServiceFonts() fid.deffontsettings.charset = DEFAULT_CHARSET;
wcsncpy(fid.deffontsettings.szFace, fontOptionsList[i].szDefFace, _countof(fid.deffontsettings.szFace));
wcsncpy(fid.backgroundName, fontOptionsList[i].szBkgName, _countof(fid.backgroundName));
- FontRegisterT(&fid);
+ FontRegisterW(&fid);
}
- ColourIDT cid = { sizeof(cid) };
+ ColourIDW cid = { sizeof(cid) };
wcsncpy_s(cid.group, LPGENW("Messaging"), _TRUNCATE);
strncpy(cid.dbSettingsGroup, SRMMMOD, _countof(fid.dbSettingsGroup));
cid.flags = 0;
@@ -139,7 +139,7 @@ void RegisterFontServiceFonts() cid.defcolour = colourOptionsList[i].defColour;
strncpy(cid.setting, colourOptionsList[i].szSettingName, _countof(cid.setting));
- ColourRegisterT(&cid);
+ ColourRegisterW(&cid);
}
}
@@ -188,7 +188,7 @@ void LoadMsgDlgFont(int i, LOGFONT *lf, COLORREF *colour) lf->lfPitchAndFamily = DEFAULT_PITCH | FF_DONTCARE;
mir_snprintf(str, "%s%d", "SRMFont", i);
- ptrW tszFace(db_get_tsa(NULL, SRMMMOD, str));
+ ptrW tszFace(db_get_wsa(NULL, SRMMMOD, str));
if (tszFace == NULL)
mir_wstrcpy(lf->lfFaceName, fontOptionsList[i].szDefFace);
else
@@ -227,7 +227,7 @@ static void FillCheckBoxTree(HWND hwndTree, const struct CheckBoxValues_t *value tvis.item.mask = TVIF_PARAM | TVIF_TEXT | TVIF_STATE;
for (int i = 0; i < nValues; i++) {
tvis.item.lParam = values[i].style;
- tvis.item.pszText = TranslateTS(values[i].szDescr);
+ tvis.item.pszText = TranslateW(values[i].szDescr);
tvis.item.stateMask = TVIS_STATEIMAGEMASK;
tvis.item.state = INDEXTOSTATEIMAGEMASK((style & tvis.item.lParam) != 0 ? 2 : 1);
TreeView_InsertItem(hwndTree, &tvis);
diff --git a/plugins/Scriver/src/msgwindow.cpp b/plugins/Scriver/src/msgwindow.cpp index 8744cb1b64..0443ba8534 100644 --- a/plugins/Scriver/src/msgwindow.cpp +++ b/plugins/Scriver/src/msgwindow.cpp @@ -40,12 +40,12 @@ wchar_t* GetWindowTitle(MCONTACT hContact, const char *szProto) ptrW tmplt;
const wchar_t* tokens[4] = { 0 };
- CMString tszTemplate, tszStatus, tszTitle;
+ CMStringW tszTemplate, tszStatus, tszTitle;
if (hContact && szProto) {
tokens[0] = pcli->pfnGetContactDisplayName(hContact, 0);
tokens[1] = pcli->pfnGetStatusModeDescription(db_get_w(hContact, szProto, "Status", ID_STATUS_OFFLINE), 0);
- tszStatus = ptrW(db_get_tsa(hContact, "CList", "StatusMsg"));
+ tszStatus = ptrW(db_get_wsa(hContact, "CList", "StatusMsg"));
tszStatus.Replace(L"\r\n", L" ");
tokens[2] = tszStatus;
@@ -56,7 +56,7 @@ wchar_t* GetWindowTitle(MCONTACT hContact, const char *szProto) tokens[3] = mir_wstrdup(proto->tszAccountName);
}
- tmplt = db_get_tsa(NULL, SRMMMOD, SRMSGSET_WINDOWTITLE);
+ tmplt = db_get_wsa(NULL, SRMMMOD, SRMSGSET_WINDOWTITLE);
if (tmplt != NULL)
tszTemplate = tmplt;
else {
|