diff options
Diffstat (limited to 'protocols/WhatsApp/src/chat.cpp')
-rw-r--r-- | protocols/WhatsApp/src/chat.cpp | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/protocols/WhatsApp/src/chat.cpp b/protocols/WhatsApp/src/chat.cpp index e768dde43c..1910128775 100644 --- a/protocols/WhatsApp/src/chat.cpp +++ b/protocols/WhatsApp/src/chat.cpp @@ -165,20 +165,20 @@ void WhatsAppProto::EditChatSubject(WAChatInfo *pInfo) void WhatsAppProto::SetChatAvatar(WAChatInfo *pInfo)
{
- TCHAR tszFileName[MAX_PATH], filter[256]; + TCHAR tszFileName[MAX_PATH], filter[256];
BmpFilterGetStrings(filter, SIZEOF(filter));
- - OPENFILENAME ofn = { 0 }; - ofn.lStructSize = OPENFILENAME_SIZE_VERSION_400; - ofn.lpstrFilter = filter; - ofn.hwndOwner = 0; - ofn.lpstrFile = tszFileName; - ofn.nMaxFile = ofn.nMaxFileTitle = SIZEOF(tszFileName); - ofn.Flags = OFN_HIDEREADONLY; - ofn.lpstrInitialDir = _T("."); - ofn.lpstrDefExt = _T(""); - if (GetOpenFileName(&ofn)) - if (_taccess(tszFileName, 4) != -1) +
+ OPENFILENAME ofn = { 0 };
+ ofn.lStructSize = OPENFILENAME_SIZE_VERSION_400;
+ ofn.lpstrFilter = filter;
+ ofn.hwndOwner = 0;
+ ofn.lpstrFile = tszFileName;
+ ofn.nMaxFile = ofn.nMaxFileTitle = SIZEOF(tszFileName);
+ ofn.Flags = OFN_HIDEREADONLY;
+ ofn.lpstrInitialDir = _T(".");
+ ofn.lpstrDefExt = _T("");
+ if (GetOpenFileName(&ofn))
+ if (_taccess(tszFileName, 4) != -1)
InternalSetAvatar(pInfo->hContact, _T2A(pInfo->tszJid), tszFileName);
}
@@ -223,16 +223,16 @@ void WhatsAppProto::AddChatUser(WAChatInfo *pInfo, const TCHAR *ptszJid) if (hContact && !db_get_b(hContact, "CList", "NotInList", 0))
return;
- PROTOSEARCHRESULT sr = { 0 };
- sr.cbSize = sizeof(sr);
- sr.flags = PSR_TCHAR;
- sr.id = (TCHAR*)ptszJid;
- sr.nick = GetChatUserNick(jid);
+ PROTOSEARCHRESULT psr = { 0 };
+ psr.cbSize = sizeof(psr);
+ psr.flags = PSR_TCHAR;
+ psr.id.t = (TCHAR*)ptszJid;
+ psr.nick.t = GetChatUserNick(jid);
ADDCONTACTSTRUCT acs = { 0 };
acs.handleType = HANDLE_SEARCHRESULT;
acs.szProto = m_szModuleName;
- acs.psr = (PROTOSEARCHRESULT*)&sr;
+ acs.psr = &psr;
CallService(MS_ADDCONTACT_SHOW, (WPARAM)CallService(MS_CLUI_GETHWND, 0, 0), (LPARAM)&acs);
}
|