diff options
author | George Hazan <ghazan@miranda.im> | 2019-12-04 16:08:03 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2019-12-04 16:08:03 +0300 |
commit | 3bb16e798cb51d5764aacbefd4edf26f52d8c4f0 (patch) | |
tree | 59dbb53fc9496d660ec2ef2846a4eab0f1720b88 /plugins/BasicHistory/src | |
parent | 3216d8df5cb355f34c82ed10b7e40bab7525b697 (diff) |
GetContactProto: useless duplicate function replaced with standard Proto_GetBaseAccountName
Diffstat (limited to 'plugins/BasicHistory/src')
-rw-r--r-- | plugins/BasicHistory/src/DatExport.cpp | 2 | ||||
-rw-r--r-- | plugins/BasicHistory/src/EventList.cpp | 8 | ||||
-rw-r--r-- | plugins/BasicHistory/src/HistoryWindow.cpp | 2 |
3 files changed, 6 insertions, 6 deletions
diff --git a/plugins/BasicHistory/src/DatExport.cpp b/plugins/BasicHistory/src/DatExport.cpp index c21a030abe..c6a020fb05 100644 --- a/plugins/BasicHistory/src/DatExport.cpp +++ b/plugins/BasicHistory/src/DatExport.cpp @@ -151,7 +151,7 @@ bool DatExport::GetEventList(std::vector<IImport::ExternalMessage>& eventList) dataSize = header.dataSize;
DBEVENTINFO86 messageHeader;
DBEVENTINFO info = {};
- info.szModule = GetContactProto(hContact);
+ info.szModule = Proto_GetBaseAccountName(hContact);
wchar_t _str[MAXSELECTSTR + 8]; // for safety reason
std::multimap<DWORD, IImport::ExternalMessage> sortedEvents;
while (dataSize > 0) {
diff --git a/plugins/BasicHistory/src/EventList.cpp b/plugins/BasicHistory/src/EventList.cpp index 8e3b635be2..834cc025fa 100644 --- a/plugins/BasicHistory/src/EventList.cpp +++ b/plugins/BasicHistory/src/EventList.cpp @@ -394,7 +394,7 @@ std::wstring HistoryEventList::GetContactName() std::wstring HistoryEventList::GetMyName()
{
- ptrW name(Contact_GetInfo(CNF_DISPLAY, NULL, GetContactProto(m_hContact)));
+ ptrW name(Contact_GetInfo(CNF_DISPLAY, NULL, Proto_GetBaseAccountName(m_hContact)));
return (name == NULL) ? TranslateT("Me") : name;
}
@@ -421,13 +421,13 @@ std::wstring HistoryEventList::GetProtocolName() std::string HistoryEventList::GetBaseProtocol()
{
- char* proto = GetContactProto(m_hContact);
+ char* proto = Proto_GetBaseAccountName(m_hContact);
return proto == nullptr ? "" : proto;
}
std::wstring HistoryEventList::GetMyId()
{
- ptrW id(Contact_GetInfo(CNF_DISPLAYUID, NULL, GetContactProto(m_hContact)));
+ ptrW id(Contact_GetInfo(CNF_DISPLAYUID, NULL, Proto_GetBaseAccountName(m_hContact)));
return (id == NULL) ? L"" : id;
}
@@ -495,7 +495,7 @@ void HistoryEventList::MargeMessages(const std::vector<IImport::ExternalMessage> GetTempList(tempList, true, false, m_hContact);
DBEVENTINFO dbei = {};
- dbei.szModule = GetContactProto(m_hContact);
+ dbei.szModule = Proto_GetBaseAccountName(m_hContact);
db_set_safety_mode(FALSE);
for (std::list<EventTempIndex>::iterator it = tempList.begin(); it != tempList.end(); ++it) {
diff --git a/plugins/BasicHistory/src/HistoryWindow.cpp b/plugins/BasicHistory/src/HistoryWindow.cpp index 7c393354ee..22053a663c 100644 --- a/plugins/BasicHistory/src/HistoryWindow.cpp +++ b/plugins/BasicHistory/src/HistoryWindow.cpp @@ -1245,7 +1245,7 @@ void HistoryWindow::ReplaceIcons(HWND hwndDlg, int selStart, BOOL isSent) SMADD_RICHEDIT3 smadd = { 0 };
smadd.cbSize = sizeof(smadd);
smadd.hwndRichEditControl = hwndDlg;
- smadd.Protocolname = GetContactProto(m_hContact);
+ smadd.Protocolname = Proto_GetBaseAccountName(m_hContact);
smadd.hContact = m_hContact;
smadd.flags = isSent ? SAFLRE_OUTGOING : 0;
if (selStart > 0)
|