From 371db973914f270432e914922b735e01279c5db8 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Wed, 12 Feb 2014 14:12:44 +0000 Subject: another bunch of useless conversions died git-svn-id: http://svn.miranda-ng.org/main/trunk@8109 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/JabberG/src/jabber_chat.cpp | 12 ++++++------ protocols/JabberG/src/jabber_disco.cpp | 6 +++--- protocols/JabberG/src/jabber_iqid.cpp | 2 +- protocols/JabberG/src/jabber_proto.cpp | 4 ++-- protocols/JabberG/src/jabber_rc.cpp | 2 +- protocols/JabberG/src/jabber_svc.cpp | 4 ++-- protocols/JabberG/src/jabber_thread.cpp | 16 ++++++++-------- protocols/JabberG/src/jabber_xstatus.cpp | 2 +- protocols/JabberG/src/ui_utils.cpp | 4 ++-- 9 files changed, 26 insertions(+), 26 deletions(-) (limited to 'protocols/JabberG/src') diff --git a/protocols/JabberG/src/jabber_chat.cpp b/protocols/JabberG/src/jabber_chat.cpp index f11323d14a..f6793bf76c 100644 --- a/protocols/JabberG/src/jabber_chat.cpp +++ b/protocols/JabberG/src/jabber_chat.cpp @@ -602,7 +602,7 @@ int CJabberProto::JabberGcMenuHook(WPARAM, LPARAM lParam) if (MCONTACT hContact = HContactFromJID(him->m_tszRealJid)) { gcmi->Item[3].uType = MENU_HMENU; - gcmi->Item[3].dwID = CallService(MS_CLIST_MENUBUILDCONTACT, (WPARAM)hContact, 0); + gcmi->Item[3].dwID = CallService(MS_CLIST_MENUBUILDCONTACT, hContact, 0); sttShowGcMenuItems(gcmi, sttRJidItems, 0); } else { @@ -743,7 +743,7 @@ public: MCONTACT hContact = m_proto->HContactFromJID(buf); if (hContact) { - int hItem = SendDlgItemMessage(m_hwnd, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0); + int hItem = SendDlgItemMessage(m_hwnd, IDC_CLIST, CLM_FINDCONTACT, hContact, 0); if (hItem) SendDlgItemMessage(m_hwnd, IDC_CLIST, CLM_SETCHECKMARK, hItem, 1); return; @@ -780,7 +780,7 @@ public: if (m_proto->isChatRoom(hContact)) continue; - if (int hItem = SendMessage(hwndList, CLM_FINDCONTACT, (WPARAM)hContact, 0)) { + if (int hItem = SendMessage(hwndList, CLM_FINDCONTACT, hContact, 0)) { if (SendMessage(hwndList, CLM_GETCHECKMARK, (WPARAM)hItem, 0)) { ptrT jid(m_proto->getTStringA(hContact, "jid")); if (jid != NULL) @@ -1040,7 +1040,7 @@ static void sttNickListHook(CJabberProto *ppro, JABBER_LIST_ITEM *item, GCHOOK* ppro->ListAddResource(LIST_VCARD_TEMP, jsr.jid, him->m_iStatus, him->m_tszStatusMessage, him->m_iPriority); MCONTACT hContact = (MCONTACT)CallProtoService(ppro->m_szModuleName, PS_ADDTOLIST, PALF_TEMPORARY, (LPARAM)&jsr); - CallService(MS_USERINFO_SHOWDIALOG, (WPARAM)hContact, 0); + CallService(MS_USERINFO_SHOWDIALOG, hContact, 0); } break; @@ -1212,7 +1212,7 @@ static void sttNickListHook(CJabberProto *ppro, JABBER_LIST_ITEM *item, GCHOOK* ppro->ListAddResource(LIST_VCARD_TEMP, jsr.jid, him->m_iStatus, him->m_tszStatusMessage, him->m_iPriority); hContact = (MCONTACT)CallProtoService(ppro->m_szModuleName, PS_ADDTOLIST, PALF_TEMPORARY, (LPARAM)&jsr); - CallService(MS_USERINFO_SHOWDIALOG, (WPARAM)hContact, 0); + CallService(MS_USERINFO_SHOWDIALOG, hContact, 0); } break; @@ -1378,7 +1378,7 @@ static void sttSendPrivateMessage(CJabberProto *ppro, JABBER_LIST_ITEM *item, co db_set_b(hContact, "CList", "Hidden", 1); ppro->setTString(hContact, "Nick", nick); db_set_dw(hContact, "Ignore", "Mask1", 0); - CallService(MS_MSG_SENDMESSAGE, (WPARAM)hContact, 0); + CallService(MS_MSG_SENDMESSAGE, hContact, 0); } } diff --git a/protocols/JabberG/src/jabber_disco.cpp b/protocols/JabberG/src/jabber_disco.cpp index b4722a2b2b..cf78440832 100644 --- a/protocols/JabberG/src/jabber_disco.cpp +++ b/protocols/JabberG/src/jabber_disco.cpp @@ -1239,7 +1239,7 @@ void CJabberProto::ServiceDiscoveryShowMenu(CJabberSDNode *pNode, HTREELISTITEM if (items[i].title) { MCONTACT hContact; if ((items[i].action == SD_ACT_USERMENU) && (hContact = HContactFromJID(pNode->GetJid()))) { - HMENU hContactMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT, (WPARAM)hContact, 0); + HMENU hContactMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT, hContact, 0); AppendMenu(hMenu, MF_STRING|MF_POPUP, (UINT_PTR)hContactMenu, TranslateTS(items[i].title)); } else AppendMenu(hMenu, MF_STRING, items[i].action, TranslateTS(items[i].title)); @@ -1403,7 +1403,7 @@ void CJabberProto::ServiceDiscoveryShowMenu(CJabberSDNode *pNode, HTREELISTITEM JABBER_LIST_ITEM *item = ListAdd(LIST_VCARD_TEMP, pNode->GetJid()); item->bUseResource = TRUE; } - HMENU hContactMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT, (WPARAM)hContact, 0); + HMENU hContactMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT, hContact, 0); GetCursorPos(&pt); int res = TrackPopupMenu(hContactMenu, TPM_RETURNCMD, pt.x, pt.y, 0, m_pDlgServiceDiscovery->GetHwnd(), NULL); CallService(MS_CLIST_MENUPROCESSCOMMAND, MAKEWPARAM(res, MPCF_CONTACTMENU), (LPARAM)hContact); @@ -1426,7 +1426,7 @@ void CJabberProto::ServiceDiscoveryShowMenu(CJabberSDNode *pNode, HTREELISTITEM if (item->arResources.getCount() == 0) ListAddResource(LIST_VCARD_TEMP, jid, ID_STATUS_OFFLINE, NULL, 0); } - CallService(MS_USERINFO_SHOWDIALOG, (WPARAM)hContact, 0); + CallService(MS_USERINFO_SHOWDIALOG, hContact, 0); } break; diff --git a/protocols/JabberG/src/jabber_iqid.cpp b/protocols/JabberG/src/jabber_iqid.cpp index acb1ce6fe6..5421d2f45e 100644 --- a/protocols/JabberG/src/jabber_iqid.cpp +++ b/protocols/JabberG/src/jabber_iqid.cpp @@ -501,7 +501,7 @@ void CJabberProto::OnIqResultGetRoster(HXML iqNode, CJabberIqInfo *pInfo) ptrT jid( getTStringA(hContact, "jid")); if (jid != NULL && !ListGetItemPtr(LIST_ROSTER, jid)) { debugLogA("Syncing roster: preparing to delete %S (hContact=0x%x)", jid, hContact); - CallService(MS_DB_CONTACT_DELETE, (WPARAM)hContact, 0); + CallService(MS_DB_CONTACT_DELETE, hContact, 0); } hContact = hNext; } diff --git a/protocols/JabberG/src/jabber_proto.cpp b/protocols/JabberG/src/jabber_proto.cpp index b380fa7276..4c88c7ca4b 100644 --- a/protocols/JabberG/src/jabber_proto.cpp +++ b/protocols/JabberG/src/jabber_proto.cpp @@ -326,7 +326,7 @@ MCONTACT CJabberProto::AddToListByJID(const TCHAR *newJid, DWORD flags) jid = mir_tstrdup(newJid); debugLogA("Add new jid to contact jid = %S", jid); hContact = (MCONTACT)CallService(MS_DB_CONTACT_ADD, 0, 0); - CallService(MS_PROTO_ADDTOCONTACT, (WPARAM)hContact, (LPARAM)m_szModuleName); + CallService(MS_PROTO_ADDTOCONTACT, hContact, (LPARAM)m_szModuleName); setTString(hContact, "jid", jid); if ((nick=JabberNickFromJID(newJid)) == NULL) nick = mir_tstrdup(newJid); @@ -1427,7 +1427,7 @@ void CJabberProto::InfoFrame_OnTransport(CJabberInfoFrame_Event *evt) { if (evt->m_event == CJabberInfoFrame_Event::CLICK) { MCONTACT hContact = (MCONTACT)evt->m_pUserData; - HMENU hContactMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT, (WPARAM)hContact, 0); + HMENU hContactMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT, hContact, 0); POINT pt; GetCursorPos(&pt); int res = TrackPopupMenu(hContactMenu, TPM_RETURNCMD, pt.x, pt.y, 0, (HWND)CallService(MS_CLUI_GETHWND, 0, 0), NULL); diff --git a/protocols/JabberG/src/jabber_rc.cpp b/protocols/JabberG/src/jabber_rc.cpp index a4cbc67229..b1ae868e3a 100644 --- a/protocols/JabberG/src/jabber_rc.cpp +++ b/protocols/JabberG/src/jabber_rc.cpp @@ -605,7 +605,7 @@ int CJabberProto::AdhocForwardHandler(HXML, CJabberIqInfo *pInfo, CJabberAdhocSe db_event_markRead(hContact, hDbEvent); if (bRemoveCListEvents) - CallService(MS_CLIST_REMOVEEVENT, (WPARAM)hContact, (LPARAM)hDbEvent); + CallService(MS_CLIST_REMOVEEVENT, hContact, (LPARAM)hDbEvent); } } diff --git a/protocols/JabberG/src/jabber_svc.cpp b/protocols/JabberG/src/jabber_svc.cpp index 59f9086632..dc3b1d9418 100644 --- a/protocols/JabberG/src/jabber_svc.cpp +++ b/protocols/JabberG/src/jabber_svc.cpp @@ -466,7 +466,7 @@ INT_PTR __cdecl CJabberProto::JabberServiceParseXmppURI(WPARAM, LPARAM lParam) } } - CallService(MS_MSG_SENDMESSAGEW, (WPARAM)hContact, (LPARAM)szMsgBody); + CallService(MS_MSG_SENDMESSAGEW, hContact, (LPARAM)szMsgBody); return 0; } @@ -525,7 +525,7 @@ INT_PTR __cdecl CJabberProto::JabberServiceParseXmppURI(WPARAM, LPARAM lParam) hContact = DBCreateContact(szJid, szJid, TRUE, TRUE); if (hContact == NULL) return 1; - CallService(MS_FILE_SENDFILE, (WPARAM)hContact, (LPARAM)NULL); + CallService(MS_FILE_SENDFILE, hContact, (LPARAM)NULL); return 0; } diff --git a/protocols/JabberG/src/jabber_thread.cpp b/protocols/JabberG/src/jabber_thread.cpp index 41c7238f64..1eb7a05e0a 100644 --- a/protocols/JabberG/src/jabber_thread.cpp +++ b/protocols/JabberG/src/jabber_thread.cpp @@ -1167,15 +1167,15 @@ void CJabberProto::OnProcessMessage(HXML node, ThreadData* info) // chatstates composing event if (hContact && xmlGetChildByTag(node, "composing", "xmlns", JABBER_FEAT_CHATSTATES)) - CallService(MS_PROTO_CONTACTISTYPING, (WPARAM)hContact, 60); + CallService(MS_PROTO_CONTACTISTYPING, hContact, 60); // chatstates paused event if (hContact && xmlGetChildByTag(node, "paused", "xmlns", JABBER_FEAT_CHATSTATES)) - CallService(MS_PROTO_CONTACTISTYPING, (WPARAM)hContact, PROTOTYPE_CONTACTTYPING_OFF); + CallService(MS_PROTO_CONTACTISTYPING, hContact, PROTOTYPE_CONTACTTYPING_OFF); // chatstates inactive event if (hContact && xmlGetChildByTag(node, "inactive", "xmlns", JABBER_FEAT_CHATSTATES)) { - CallService(MS_PROTO_CONTACTISTYPING, (WPARAM)hContact, PROTOTYPE_CONTACTTYPING_OFF); + CallService(MS_PROTO_CONTACTISTYPING, hContact, PROTOTYPE_CONTACTTYPING_OFF); if (pFromResource) pFromResource->m_bMessageSessionActive = false; } @@ -1196,7 +1196,7 @@ void CJabberProto::OnProcessMessage(HXML node, ThreadData* info) if (!hContact) hContact = CreateTemporaryContact(from, chatItem); if (hContact) - NotifyEventHooks(m_hEventNudge, (WPARAM)hContact, 0); + NotifyEventHooks(m_hEventNudge, hContact, 0); } // chatstates gone event @@ -1290,12 +1290,12 @@ void CJabberProto::OnProcessMessage(HXML node, ThreadData* info) } if (hContact && xmlGetChild(xNode, "composing") != NULL) - CallService(MS_PROTO_CONTACTISTYPING, (WPARAM)hContact, 60); + CallService(MS_PROTO_CONTACTISTYPING, hContact, 60); // Maybe a cancel to the previous composing HXML child = xmlGetChild(xNode, 0); if (hContact && (!child || (child && idNode != NULL))) - CallService(MS_PROTO_CONTACTISTYPING, (WPARAM)hContact, PROTOTYPE_CONTACTTYPING_OFF); + CallService(MS_PROTO_CONTACTISTYPING, hContact, PROTOTYPE_CONTACTTYPING_OFF); } else { // Check whether any event is requested @@ -1360,7 +1360,7 @@ void CJabberProto::OnProcessMessage(HXML node, ThreadData* info) else if (!_tcscmp(action, _T("delete"))) { MCONTACT hContact = HContactFromJID(jid); if (hContact) - CallService(MS_DB_CONTACT_DELETE, (WPARAM)hContact, 0); + CallService(MS_DB_CONTACT_DELETE, hContact, 0); } } } @@ -1418,7 +1418,7 @@ void CJabberProto::OnProcessMessage(HXML node, ThreadData* info) // Create a temporary contact, if needed if (hContact == NULL) hContact = CreateTemporaryContact(from, chatItem); - CallService(MS_PROTO_CONTACTISTYPING, (WPARAM)hContact, PROTOTYPE_CONTACTTYPING_OFF); + CallService(MS_PROTO_CONTACTISTYPING, hContact, PROTOTYPE_CONTACTTYPING_OFF); time_t now = time(NULL); if (!msgTime) diff --git a/protocols/JabberG/src/jabber_xstatus.cpp b/protocols/JabberG/src/jabber_xstatus.cpp index 4d2bd7942e..b678dedbc2 100644 --- a/protocols/JabberG/src/jabber_xstatus.cpp +++ b/protocols/JabberG/src/jabber_xstatus.cpp @@ -729,7 +729,7 @@ void CPepMood::SetMood(MCONTACT hContact, const TCHAR *szMood, const TCHAR *szTe m_proto->ResetAdvStatus(hContact, ADVSTATUS_MOOD); } - NotifyEventHooks(m_proto->m_hEventXStatusChanged, (WPARAM)hContact, 0); + NotifyEventHooks(m_proto->m_hEventXStatusChanged, hContact, 0); } void CPepMood::ShowSetDialog(BYTE bQuiet) diff --git a/protocols/JabberG/src/ui_utils.cpp b/protocols/JabberG/src/ui_utils.cpp index 45303df0bc..6847c8be3b 100644 --- a/protocols/JabberG/src/ui_utils.cpp +++ b/protocols/JabberG/src/ui_utils.cpp @@ -602,7 +602,7 @@ BOOL CCtrlClc::OnNotify(int, NMHDR *pnmh) } void CCtrlClc::AddContact(MCONTACT hContact) -{ SendMessage(m_hwnd, CLM_ADDCONTACT, (WPARAM)hContact, 0); +{ SendMessage(m_hwnd, CLM_ADDCONTACT, hContact, 0); } void CCtrlClc::AddGroup(HANDLE hGroup) @@ -634,7 +634,7 @@ void CCtrlClc::Expand(HANDLE hItem, DWORD flags) } HANDLE CCtrlClc::FindContact(MCONTACT hContact) -{ return (HANDLE)SendMessage(m_hwnd, CLM_FINDCONTACT, (WPARAM)hContact, 0); +{ return (HANDLE)SendMessage(m_hwnd, CLM_FINDCONTACT, hContact, 0); } HANDLE CCtrlClc::FindGroup(HANDLE hGroup) -- cgit v1.2.3