summaryrefslogtreecommitdiff
path: root/plugins/ClientChangeNotify/src
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/ClientChangeNotify/src')
-rw-r--r--plugins/ClientChangeNotify/src/ClientChangeNotify.cpp14
-rw-r--r--plugins/ClientChangeNotify/src/Common.h2
-rw-r--r--plugins/ClientChangeNotify/src/CommonLibs/CString.cpp6
-rw-r--r--plugins/ClientChangeNotify/src/CommonLibs/CString.h8
4 files changed, 15 insertions, 15 deletions
diff --git a/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp b/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp
index 9036ac1e00..c79ace857e 100644
--- a/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp
+++ b/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp
@@ -83,25 +83,25 @@ static VOID NTAPI ShowContactMenu(ULONG_PTR wParam)
void Popup_DoAction(HWND hWnd, BYTE Action, PLUGIN_DATA *pdata)
{
- HCONTACT hContact = (HCONTACT)CallService(MS_POPUP_GETCONTACT, (WPARAM)hWnd, 0);
+ MCONTACT hContact = (MCONTACT)CallService(MS_POPUP_GETCONTACT, (WPARAM)hWnd, 0);
switch (Action) {
case PCA_OPENMESSAGEWND: // open message window
- if (hContact && hContact != (HCONTACT)INVALID_HANDLE_VALUE)
+ if (hContact && hContact != INVALID_CONTACT_ID)
CallServiceSync(ServiceExists("SRMsg/LaunchMessageWindow") ? "SRMsg/LaunchMessageWindow" : MS_MSG_SENDMESSAGE, (WPARAM)hContact, 0);
break;
case PCA_OPENMENU: // open contact menu
- if (hContact && hContact != (HCONTACT)INVALID_HANDLE_VALUE)
+ if (hContact && hContact != INVALID_CONTACT_ID)
QueueUserAPC(ShowContactMenu, g_hMainThread, (ULONG_PTR)hContact);
break;
case PCA_OPENDETAILS: // open contact details window
- if (hContact != (HCONTACT)INVALID_HANDLE_VALUE)
+ if (hContact != INVALID_CONTACT_ID)
CallServiceSync(MS_USERINFO_SHOWDIALOG, (WPARAM)hContact, 0);
break;
case PCA_OPENHISTORY: // open contact history
- if (hContact != (HCONTACT)INVALID_HANDLE_VALUE)
+ if (hContact != INVALID_CONTACT_ID)
CallServiceSync(MS_HISTORY_SHOWCONTACTHISTORY, (WPARAM)hContact, 0);
break;
@@ -201,7 +201,7 @@ int ContactSettingChanged(WPARAM wParam, LPARAM lParam)
if (lstrcmpA(cws->szSetting, DB_MIRVER))
return 0;
- HCONTACT hContact = (HCONTACT)wParam;
+ MCONTACT hContact = (MCONTACT)wParam;
SHOWPOPUP_DATA sd = {0};
char *szProto = GetContactProto(hContact);
if (g_PreviewOptPage)
@@ -231,7 +231,7 @@ int ContactSettingChanged(WPARAM wParam, LPARAM lParam)
PopupOptPage.DBToMem();
}
- HCONTACT hContactOrMeta = (hContact && bMetaContactsExists) ? (HCONTACT)CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, 0) : hContact;
+ MCONTACT hContactOrMeta = (hContact && bMetaContactsExists) ? (MCONTACT)CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, 0) : hContact;
if (!hContactOrMeta)
hContactOrMeta = hContact;
diff --git a/plugins/ClientChangeNotify/src/Common.h b/plugins/ClientChangeNotify/src/Common.h
index f9ce032674..d29080795b 100644
--- a/plugins/ClientChangeNotify/src/Common.h
+++ b/plugins/ClientChangeNotify/src/Common.h
@@ -138,7 +138,7 @@ struct PLUGIN_DATA
struct SHOWPOPUP_DATA
{
- HCONTACT hContact;
+ MCONTACT hContact;
TCString OldMirVer;
TCString MirVer;
COptPage *PopupOptPage;
diff --git a/plugins/ClientChangeNotify/src/CommonLibs/CString.cpp b/plugins/ClientChangeNotify/src/CommonLibs/CString.cpp
index 52e4f69295..38d96882d5 100644
--- a/plugins/ClientChangeNotify/src/CommonLibs/CString.cpp
+++ b/plugins/ClientChangeNotify/src/CommonLibs/CString.cpp
@@ -272,19 +272,19 @@ template class TString<TCHAR>;
template class TString<char>;
template class TString<WCHAR>;
-CString db_get_s(HCONTACT hContact, const char *szModule, const char *szSetting, const char *szDefaultValue)
+CString db_get_s(MCONTACT hContact, const char *szModule, const char *szSetting, const char *szDefaultValue)
{
ptrA p( db_get_sa(hContact, szModule, szSetting));
return CString(p == NULL ? szDefaultValue : p);
}
-TCString db_get_s(HCONTACT hContact, const char *szModule, const char *szSetting, const TCHAR *szDefaultValue)
+TCString db_get_s(MCONTACT hContact, const char *szModule, const char *szSetting, const TCHAR *szDefaultValue)
{
ptrT p( db_get_tsa(hContact, szModule, szSetting));
return TCString(p == NULL ? szDefaultValue : p);
}
-TCString DBGetContactSettingAsString(HCONTACT hContact, const char *szModule, const char *szSetting, const TCHAR *szDefaultValue)
+TCString DBGetContactSettingAsString(MCONTACT hContact, const char *szModule, const char *szSetting, const TCHAR *szDefaultValue)
{ // also converts numeric values to a string
DBVARIANT dbv = {0};
int iRes = db_get_ws(hContact, szModule, szSetting, &dbv);
diff --git a/plugins/ClientChangeNotify/src/CommonLibs/CString.h b/plugins/ClientChangeNotify/src/CommonLibs/CString.h
index c1f555c72a..0d81a4f7c3 100644
--- a/plugins/ClientChangeNotify/src/CommonLibs/CString.h
+++ b/plugins/ClientChangeNotify/src/CommonLibs/CString.h
@@ -163,10 +163,10 @@ __inline CHARARRAY WCHAR2UTF8(WCString Str)
#undef db_get_s
-CString db_get_s(HCONTACT hContact, const char *szModule, const char *szSetting, const char *szDefaultValue);
-TCString db_get_s(HCONTACT hContact, const char *szModule, const char *szSetting, const TCHAR *szDefaultValue);
-int db_get_s(HCONTACT hContact, const char *szModule, const char *szSetting, DBVARIANT *dbv);
-TCString DBGetContactSettingAsString(HCONTACT hContact, const char *szModule, const char *szSetting, const TCHAR *szDefaultValue); // also converts numeric values to a string
+CString db_get_s(MCONTACT hContact, const char *szModule, const char *szSetting, const char *szDefaultValue);
+TCString db_get_s(MCONTACT hContact, const char *szModule, const char *szSetting, const TCHAR *szDefaultValue);
+int db_get_s(MCONTACT hContact, const char *szModule, const char *szSetting, DBVARIANT *dbv);
+TCString DBGetContactSettingAsString(MCONTACT hContact, const char *szModule, const char *szSetting, const TCHAR *szDefaultValue); // also converts numeric values to a string
// various string helpers. their return values are valid only while the class is visible
class UTF8Encode