summaryrefslogtreecommitdiff
path: root/plugins/SeenPlugin
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2019-02-27 12:43:20 +0300
committerGeorge Hazan <ghazan@miranda.im>2019-02-27 12:43:20 +0300
commit423be683866fd8e305457eb725d8cdbe1f297fbd (patch)
treec49a7bdaf7f08683b9bfae48f0250050b2bf1872 /plugins/SeenPlugin
parent288a07c81370226937d882b7a14fe3b6e3607e9e (diff)
popup code cleaning (cause we have no tchar.h)
Diffstat (limited to 'plugins/SeenPlugin')
-rw-r--r--plugins/SeenPlugin/src/options.cpp10
-rw-r--r--plugins/SeenPlugin/src/utils.cpp12
2 files changed, 11 insertions, 11 deletions
diff --git a/plugins/SeenPlugin/src/options.cpp b/plugins/SeenPlugin/src/options.cpp
index cb9ce008b0..7d2ed64fd5 100644
--- a/plugins/SeenPlugin/src/options.cpp
+++ b/plugins/SeenPlugin/src/options.cpp
@@ -138,7 +138,7 @@ INT_PTR CALLBACK OptsPopupsDlgProc(HWND hdlg, UINT msg, WPARAM wparam, LPARAM lp
else
idText = wparam + 20, idBack = wparam;
- POPUPDATAT ppd = { 0 };
+ POPUPDATAW ppd = { 0 };
ppd.colorBack = SendDlgItemMessage(hdlg, idBack, CPM_GETCOLOUR, 0, 0);
ppd.colorText = SendDlgItemMessage(hdlg, idText, CPM_GETCOLOUR, 0, 0);
DWORD temp = GetDWordFromColors(ppd.colorBack, ppd.colorText);
@@ -148,12 +148,12 @@ INT_PTR CALLBACK OptsPopupsDlgProc(HWND hdlg, UINT msg, WPARAM wparam, LPARAM lp
ppd.lchIcon = Skin_LoadProtoIcon(nullptr, idBack);
GetDlgItemText(hdlg, IDC_POPUPSTAMP, szstamp, _countof(szstamp));
- wcsncpy(ppd.lptzContactName, ParseString(szstamp, NULL), MAX_CONTACTNAME);
+ wcsncpy(ppd.lpwzContactName, ParseString(szstamp, NULL), MAX_CONTACTNAME);
GetDlgItemText(hdlg, IDC_POPUPSTAMPTEXT, szstamp, _countof(szstamp));
- wcsncpy(ppd.lptzText, ParseString(szstamp, NULL), MAX_SECONDLINE);
+ wcsncpy(ppd.lpwzText, ParseString(szstamp, NULL), MAX_SECONDLINE);
- PUAddPopupT(&ppd);
+ PUAddPopupW(&ppd);
SendMessage(GetParent(hdlg), PSM_CHANGED, 0, 0);
}
@@ -495,7 +495,7 @@ int OptionsInit(WPARAM wparam, LPARAM)
odp.pfnDlgProc = OptsSettingsDlgProc;
g_plugin.addOptions(wparam, &odp);
- if (ServiceExists(MS_POPUP_ADDPOPUPT)) {
+ if (ServiceExists(MS_POPUP_ADDPOPUPW)) {
odp.pszTemplate = MAKEINTRESOURCEA(IDD_POPUPS);
odp.szGroup.w = LPGENW("Popups");
odp.szTitle.w = LPGENW("Last seen");
diff --git a/plugins/SeenPlugin/src/utils.cpp b/plugins/SeenPlugin/src/utils.cpp
index 5903d50db5..3d0fb768ef 100644
--- a/plugins/SeenPlugin/src/utils.cpp
+++ b/plugins/SeenPlugin/src/utils.cpp
@@ -476,25 +476,25 @@ void ShowPopup(MCONTACT hcontact, const char * lpzProto, int newStatus)
mir_snprintf(szSetting, "Col_%d", newStatus - ID_STATUS_OFFLINE);
DWORD sett = g_plugin.getDword(szSetting, StatusColors15bits[newStatus - ID_STATUS_OFFLINE]);
- POPUPDATAT ppd = { 0 };
+ POPUPDATAW ppd = { 0 };
GetColorsFromDWord(&ppd.colorBack, &ppd.colorText, sett);
ppd.lchContact = hcontact;
ppd.lchIcon = Skin_LoadProtoIcon(lpzProto, newStatus);
if (!g_plugin.getWString("PopupStamp", &dbv)) {
- wcsncpy(ppd.lptzContactName, ParseString(dbv.pwszVal, hcontact), MAX_CONTACTNAME);
+ wcsncpy(ppd.lpwzContactName, ParseString(dbv.pwszVal, hcontact), MAX_CONTACTNAME);
db_free(&dbv);
}
- else wcsncpy(ppd.lptzContactName, ParseString(DEFAULT_POPUPSTAMP, hcontact), MAX_CONTACTNAME);
+ else wcsncpy(ppd.lpwzContactName, ParseString(DEFAULT_POPUPSTAMP, hcontact), MAX_CONTACTNAME);
if (!g_plugin.getWString("PopupStampText", &dbv)) {
- wcsncpy(ppd.lptzText, ParseString(dbv.pwszVal, hcontact), MAX_SECONDLINE);
+ wcsncpy(ppd.lpwzText, ParseString(dbv.pwszVal, hcontact), MAX_SECONDLINE);
db_free(&dbv);
}
- else wcsncpy(ppd.lptzText, ParseString(DEFAULT_POPUPSTAMPTEXT, hcontact), MAX_SECONDLINE);
+ else wcsncpy(ppd.lpwzText, ParseString(DEFAULT_POPUPSTAMPTEXT, hcontact), MAX_SECONDLINE);
ppd.PluginWindowProc = PopupDlgProc;
- PUAddPopupT(&ppd);
+ PUAddPopupW(&ppd);
}
void myPlaySound(MCONTACT hcontact, WORD newStatus, WORD oldStatus)