summaryrefslogtreecommitdiff
path: root/plugins/TabSRMM/src/chat/clist.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/TabSRMM/src/chat/clist.cpp')
-rw-r--r--plugins/TabSRMM/src/chat/clist.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/plugins/TabSRMM/src/chat/clist.cpp b/plugins/TabSRMM/src/chat/clist.cpp
index dbcbb27ee8..628a7372ab 100644
--- a/plugins/TabSRMM/src/chat/clist.cpp
+++ b/plugins/TabSRMM/src/chat/clist.cpp
@@ -105,7 +105,7 @@ HANDLE CList_AddRoom(const char* pszModule, const TCHAR* pszRoom, const TCHAR* p
BOOL CList_SetOffline(HANDLE hContact, BOOL bHide)
{
if (hContact) {
- char* szProto = (char*)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM) hContact, 0);
+ char* szProto = GetContactProto(hContact);
if (szProto == NULL)
return FALSE;
@@ -124,7 +124,7 @@ BOOL CList_SetAllOffline(BOOL bHide, const char *pszModule)
hContact = db_find_first();
while (hContact) {
- szProto = (char *) CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM) hContact, 0);
+ szProto = GetContactProto(hContact);
if (MM_FindModule(szProto)) {
if (!pszModule || (pszModule && !strcmp(pszModule, szProto))) {
int i = M->GetByte(hContact, szProto, "ChatRoom", 0);
@@ -151,7 +151,7 @@ int CList_RoomDoubleclicked(WPARAM wParam, LPARAM lParam)
if (!hContact)
return 0;
- szProto = (char*)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM) hContact, 0);
+ szProto = GetContactProto(hContact);
if (MM_FindModule(szProto)) {
if (M->GetByte(hContact, szProto, "ChatRoom", 0) == 0)
return 0;
@@ -196,7 +196,7 @@ INT_PTR CList_JoinChat(WPARAM wParam, LPARAM lParam)
{
HANDLE hContact = (HANDLE)wParam;
if ( hContact ) {
- char* szProto = (char*)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM) hContact, 0);
+ char* szProto = GetContactProto(hContact);
if ( szProto ) {
if ( DBGetContactSettingWord( hContact, szProto, "Status", 0 ) == ID_STATUS_OFFLINE )
CallProtoService( szProto, PS_JOINCHAT, wParam, lParam );
@@ -211,7 +211,7 @@ INT_PTR CList_LeaveChat(WPARAM wParam, LPARAM lParam)
{
HANDLE hContact = (HANDLE)wParam;
if ( hContact ) {
- char* szProto = (char*)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM) hContact, 0);
+ char* szProto = GetContactProto(hContact);
if ( szProto )
CallProtoService( szProto, PS_LEAVECHAT, wParam, lParam );
}
@@ -222,7 +222,7 @@ int CList_PrebuildContactMenu(WPARAM wParam, LPARAM lParam)
{
HANDLE hContact = (HANDLE)wParam;
if ( hContact ) {
- char* szProto = (char*)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM) hContact, 0);
+ char* szProto = GetContactProto(hContact);
CLISTMENUITEM clmi = {0};
clmi.cbSize = sizeof(CLISTMENUITEM);
@@ -308,7 +308,7 @@ HANDLE CList_FindRoom(const char* pszModule, const TCHAR* pszRoom)
{
HANDLE hContact = db_find_first();
while (hContact) {
- char* szProto = (char*)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM) hContact, 0);
+ char* szProto = GetContactProto(hContact);
if (szProto && !lstrcmpiA(szProto, pszModule)) {
if (M->GetByte(hContact, szProto, "ChatRoom", 0) != 0) {
DBVARIANT dbv;