From bd8a04455d9c991c15df2287e091abe4ba054efb Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sun, 25 Nov 2012 12:54:45 +0000 Subject: typed stub for MS_PROTO_GETCONTACTBASEPROTO git-svn-id: http://svn.miranda-ng.org/main/trunk@2480 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/BasicHistory/src/DatExport.cpp | 2 +- plugins/BasicHistory/src/EventList.cpp | 10 +++++----- plugins/BasicHistory/src/HistoryWindow.cpp | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) (limited to 'plugins/BasicHistory/src') diff --git a/plugins/BasicHistory/src/DatExport.cpp b/plugins/BasicHistory/src/DatExport.cpp index 0a40abd39d..06ec796904 100644 --- a/plugins/BasicHistory/src/DatExport.cpp +++ b/plugins/BasicHistory/src/DatExport.cpp @@ -156,7 +156,7 @@ bool DatExport::GetEventList(std::vector& eventList) DBEVENTINFO86 messageHeader; DBEVENTINFO info = {0}; info.cbSize = sizeof(DBEVENTINFO); - info.szModule = (char *)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM)hContact, 0); + info.szModule = GetContactProto(hContact); TCHAR _str[MAXSELECTSTR + 8]; // for safety reason std::multimap sortedEvents; while(dataSize > 0) diff --git a/plugins/BasicHistory/src/EventList.cpp b/plugins/BasicHistory/src/EventList.cpp index e6bf5ef0d3..930f8827bc 100644 --- a/plugins/BasicHistory/src/EventList.cpp +++ b/plugins/BasicHistory/src/EventList.cpp @@ -507,7 +507,7 @@ std::wstring EventList::GetMyName() CONTACTINFO ci; ZeroMemory(&ci, sizeof(ci)); ci.cbSize = sizeof(ci); - ci.szProto = (char *)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM)hContact, 0); + ci.szProto = GetContactProto(hContact); ci.hContact = 0; ci.dwFlag = CNF_DISPLAY | CNF_TCHAR; GetInfo(ci, myName); @@ -544,7 +544,7 @@ std::wstring EventList::GetProtocolName() std::string EventList::GetBaseProtocol() { - char* proto = (char *)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM)hContact, 0); + char* proto = GetContactProto(hContact); return proto == NULL ? "" : proto; } @@ -554,7 +554,7 @@ std::wstring EventList::GetMyId() CONTACTINFO ci; ZeroMemory(&ci, sizeof(ci)); ci.cbSize = sizeof(ci); - ci.szProto = (char *)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM)hContact, 0); + ci.szProto = GetContactProto(hContact); ci.hContact = 0; ci.dwFlag = CNF_DISPLAYUID | CNF_TCHAR; GetInfo(ci, myId); @@ -567,7 +567,7 @@ inline std::wstring GetContactId(HANDLE hContact) CONTACTINFO ci; ZeroMemory(&ci, sizeof(ci)); ci.cbSize = sizeof(ci); - ci.szProto = (char *)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM)hContact, 0); + ci.szProto = GetContactProto(hContact); ci.hContact = hContact; ci.dwFlag = CNF_DISPLAYUID | CNF_TCHAR; GetInfo(ci, id); @@ -723,7 +723,7 @@ void EventList::MargeMessages(const std::vector& messa GetTempList(tempList, true, false, hContact); DBEVENTINFO dbei = {0}; dbei.cbSize = sizeof(DBEVENTINFO); - dbei.szModule = (char *)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM)hContact, 0); + dbei.szModule = GetContactProto(hContact); CallService(MS_DB_SETSAFETYMODE, (WPARAM)FALSE, 0); for(std::list::iterator it = tempList.begin(); it != tempList.end(); ++it) { diff --git a/plugins/BasicHistory/src/HistoryWindow.cpp b/plugins/BasicHistory/src/HistoryWindow.cpp index 844dedc14c..dfde02eb0b 100644 --- a/plugins/BasicHistory/src/HistoryWindow.cpp +++ b/plugins/BasicHistory/src/HistoryWindow.cpp @@ -1516,7 +1516,7 @@ void HistoryWindow::ReplaceIcons(HWND hwndDlg, int selStart, BOOL isSent) smadd.cbSize = sizeof(smadd); smadd.hwndRichEditControl = hwndDlg; - smadd.Protocolname = (char *)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM)hContact, 0); + smadd.Protocolname = GetContactProto(hContact); smadd.hContact = hContact; smadd.flags = isSent ? SAFLRE_OUTGOING : 0; if (selStart > 0) -- cgit v1.2.3