summaryrefslogtreecommitdiff
path: root/plugins/WinterSpeak
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2015-06-30 18:59:38 +0000
committerGeorge Hazan <george.hazan@gmail.com>2015-06-30 18:59:38 +0000
commit10bc9e42dfba6ed8be41199243d688c2e367dc0d (patch)
tree891aca91eeb2feddb6c76498c4eb880689360fe6 /plugins/WinterSpeak
parent5dac5be47f2d9af8cbceead6511ff4c0fc40bab5 (diff)
MS_CLIST_GETSTATUSMODEDESCRIPTION & MS_CLIST_GETCONTACTDISPLAYNAME replaced with pcli->* members
git-svn-id: http://svn.miranda-ng.org/main/trunk@14459 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/WinterSpeak')
-rw-r--r--plugins/WinterSpeak/src/Common.h2
-rw-r--r--plugins/WinterSpeak/src/UserInformation.cpp23
-rw-r--r--plugins/WinterSpeak/src/main.cpp6
3 files changed, 13 insertions, 18 deletions
diff --git a/plugins/WinterSpeak/src/Common.h b/plugins/WinterSpeak/src/Common.h
index 692a412ae3..b51cc56ff8 100644
--- a/plugins/WinterSpeak/src/Common.h
+++ b/plugins/WinterSpeak/src/Common.h
@@ -14,7 +14,7 @@
#include <m_options.h>
#include <m_protocols.h>
#include <m_protosvc.h>
-#include <m_clistint.h>
+#include <m_clist.h>
#include <m_skin.h>
#include <m_icolib.h>
#include <m_netlib.h>
diff --git a/plugins/WinterSpeak/src/UserInformation.cpp b/plugins/WinterSpeak/src/UserInformation.cpp
index 9b24734afe..43f02605fa 100644
--- a/plugins/WinterSpeak/src/UserInformation.cpp
+++ b/plugins/WinterSpeak/src/UserInformation.cpp
@@ -46,14 +46,11 @@ std::wstring UserInformation::statusString(MCONTACT user)
//------------------------------------------------------------------------------
std::wstring UserInformation::statusModeString(MCONTACT user)
{
- int status = CallService(MS_CLIST_GETSTATUSMODEDESCRIPTION, m_status_info[user], 0);
+ WCHAR *status = pcli->pfnGetStatusModeDescription(m_status_info[user], 0);
+ if (NULL == status)
+ return L"";
- if (NULL == status)
- {
- return L"";
- }
-
- return reinterpret_cast<WCHAR *>(status);
+ return status;
}
//------------------------------------------------------------------------------
@@ -66,13 +63,11 @@ void UserInformation::insertName(std::wstring &str, MCONTACT user) const
//------------------------------------------------------------------------------
std::wstring UserInformation::nameString(MCONTACT user) const
{
- //WCHAR *ret = reinterpret_cast<WCHAR *>(CallService(MS_CLIST_GETCONTACTDISPLAYNAME, reinterpret_cast<unsigned int>(user), 0));
- char* ret = (char *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, WPARAM(user), 0);
- if (0 == ret)
- {
- return L"";
- }
- return TranslateW(mir_a2t_cp(ret, CP_UTF8));
+ WCHAR *ret = pcli->pfnGetContactDisplayName(user, 0);
+ if (0 == ret)
+ return L"";
+
+ return TranslateW(ret);
}
//==============================================================================
diff --git a/plugins/WinterSpeak/src/main.cpp b/plugins/WinterSpeak/src/main.cpp
index 4a5c831517..554ee64ee4 100644
--- a/plugins/WinterSpeak/src/main.cpp
+++ b/plugins/WinterSpeak/src/main.cpp
@@ -1,6 +1,6 @@
#include "Common.h"
-
+CLIST_INTERFACE *pcli;
HINSTANCE g_hInst;
int hLangpack;
DWORD g_mirandaVersion;
@@ -105,8 +105,8 @@ extern "C" __declspec(dllexport) PLUGININFOEX* MirandaPluginInfoEx(DWORD miranda
extern "C" __declspec(dllexport) int Load(void)
{
- mir_getLP( &pluginInfo );
- //pluginLink = link;
+ mir_getLP(&pluginInfo);
+ mir_getCLI();
if (!g_speak_config)
{