diff options
author | George Hazan <ghazan@miranda.im> | 2018-04-05 22:10:25 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-04-05 22:10:25 +0300 |
commit | 35e2289786a7f1542573d1a58ebc971970ea981c (patch) | |
tree | da8887c793611fdbf6072fd477fd8c01c60b8b02 /plugins/AvatarHistory/src | |
parent | f7c00d6dc53774d16b9721e79ed5d4017af63884 (diff) |
CLIST_INTERFACE::pfnGetContactDisplayName => Clist_GetContactDisplayName
Diffstat (limited to 'plugins/AvatarHistory/src')
-rw-r--r-- | plugins/AvatarHistory/src/AvatarDlg.cpp | 4 | ||||
-rw-r--r-- | plugins/AvatarHistory/src/AvatarHistory.cpp | 2 | ||||
-rw-r--r-- | plugins/AvatarHistory/src/popup.cpp | 6 |
3 files changed, 4 insertions, 8 deletions
diff --git a/plugins/AvatarHistory/src/AvatarDlg.cpp b/plugins/AvatarHistory/src/AvatarDlg.cpp index 4bbd6495e5..987d5cf803 100644 --- a/plugins/AvatarHistory/src/AvatarDlg.cpp +++ b/plugins/AvatarHistory/src/AvatarDlg.cpp @@ -125,7 +125,7 @@ static INT_PTR CALLBACK AvatarDlgProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARA else
FillAvatarListFromFiles(hwndList, data->hContact);
- wchar_t *displayName = pcli->pfnGetContactDisplayName(data->hContact, 0);
+ wchar_t *displayName = Clist_GetContactDisplayName(data->hContact);
if (displayName) {
wchar_t title[MAX_PATH];
mir_snwprintf(title, TranslateT("Avatar history for %s"), displayName);
@@ -530,7 +530,7 @@ int ShowSaveDialog(HWND hwnd, wchar_t* fn, MCONTACT hContact) wcsncpy_s(file, (wcsrchr(fn, '\\') + 1), _TRUNCATE);
ofn.lpstrFile = file;
- wchar_t *displayName = pcli->pfnGetContactDisplayName(hContact, 0);
+ wchar_t *displayName = Clist_GetContactDisplayName(hContact);
wchar_t title[MAX_PATH];
if (displayName) {
mir_snwprintf(title, TranslateT("Save avatar for %s"), displayName);
diff --git a/plugins/AvatarHistory/src/AvatarHistory.cpp b/plugins/AvatarHistory/src/AvatarHistory.cpp index 3e1d86f3f8..476171afdd 100644 --- a/plugins/AvatarHistory/src/AvatarHistory.cpp +++ b/plugins/AvatarHistory/src/AvatarHistory.cpp @@ -23,7 +23,6 @@ Avatar History Plugin */
#include "stdafx.h"
-CLIST_INTERFACE *pcli;
HINSTANCE hInst;
DWORD mirVer;
@@ -291,7 +290,6 @@ static INT_PTR CALLBACK FirstRunDlgProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPA extern "C" __declspec(dllexport) int Load(void)
{
mir_getLP(&pluginInfo);
- pcli = Clist_GetInterface();
CoInitialize(nullptr);
diff --git a/plugins/AvatarHistory/src/popup.cpp b/plugins/AvatarHistory/src/popup.cpp index 6d4ef5c8ab..2b5dfd3165 100644 --- a/plugins/AvatarHistory/src/popup.cpp +++ b/plugins/AvatarHistory/src/popup.cpp @@ -104,8 +104,7 @@ void ShowPopupEx(MCONTACT hContact, const wchar_t *title, const wchar_t *descrip if (title != nullptr)
mir_wstrncpy(ppd.lptzContactName, title, _countof(ppd.lptzContactName));
else if (hContact != NULL)
- mir_wstrncpy(ppd.lptzContactName, (wchar_t *)pcli->pfnGetContactDisplayName(hContact, 0),
- _countof(ppd.lptzContactName));
+ mir_wstrncpy(ppd.lptzContactName, Clist_GetContactDisplayName(hContact), _countof(ppd.lptzContactName));
if (description != nullptr)
mir_wstrncpy(ppd.lptzText, description, _countof(ppd.lptzText));
@@ -163,8 +162,7 @@ void ShowPopupEx(MCONTACT hContact, const wchar_t *title, const wchar_t *descrip PUAddPopupT(&ppd);
}
else {
- MessageBox(nullptr, description, title ? title : (wchar_t *)pcli->pfnGetContactDisplayName(hContact, 0),
- MB_OK);
+ MessageBox(nullptr, description, title ? title : Clist_GetContactDisplayName(hContact), MB_OK);
}
}
|