diff options
author | George Hazan <george.hazan@gmail.com> | 2013-08-16 14:34:41 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2013-08-16 14:34:41 +0000 |
commit | 35489ce3659220b4ebd25d1b3ab0258115cf10a4 (patch) | |
tree | 611d9ebaa2f85129af43492368381c55ccbb1a5e /protocols/Tlen/src/tlen_userinfo.cpp | |
parent | 2611fbb22f7e186cb989f2b16133dad5215e41e1 (diff) |
Tlen:
- custom base64 removed;
- strict prototype verification
git-svn-id: http://svn.miranda-ng.org/main/trunk@5719 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Tlen/src/tlen_userinfo.cpp')
-rw-r--r-- | protocols/Tlen/src/tlen_userinfo.cpp | 27 |
1 files changed, 11 insertions, 16 deletions
diff --git a/protocols/Tlen/src/tlen_userinfo.cpp b/protocols/Tlen/src/tlen_userinfo.cpp index 933841fd3f..8361bbee92 100644 --- a/protocols/Tlen/src/tlen_userinfo.cpp +++ b/protocols/Tlen/src/tlen_userinfo.cpp @@ -127,33 +127,28 @@ static void FetchCombo(HWND hwndDlg, UINT idCtrl, char *fieldName, char **str, i }
}
-
-int TlenUserInfoInit(void *ptr, WPARAM wParam, LPARAM lParam)
+int TlenProtocol::UserInfoInit(WPARAM wParam, LPARAM lParam)
{
- char *szProto;
- HANDLE hContact;
- OPTIONSDIALOGPAGE odp = {0};
- TlenProtocol *proto = (TlenProtocol *)ptr;
-
- if (!CallService(MS_PROTO_ISPROTOCOLLOADED, 0, (LPARAM) proto->m_szModuleName))
+ if (!CallService(MS_PROTO_ISPROTOCOLLOADED, 0, (LPARAM)m_szModuleName))
return 0;
- hContact = (HANDLE) lParam;
- szProto = GetContactProto(hContact);
- if ((szProto != NULL && !strcmp(szProto, proto->m_szModuleName)) || !lParam) {
- odp.cbSize = sizeof(odp);
+
+ HANDLE hContact = (HANDLE) lParam;
+ char *szProto = GetContactProto(hContact);
+ if ((szProto != NULL && !strcmp(szProto, m_szModuleName)) || !lParam) {
+ OPTIONSDIALOGPAGE odp = { sizeof(odp) };
odp.hInstance = hInst;
odp.flags = ODPF_TCHAR;
odp.pfnDlgProc = TlenUserInfoDlgProc;
odp.position = -2000000000;
odp.pszTemplate = ((HANDLE)lParam != NULL) ? MAKEINTRESOURCEA(IDD_USER_INFO):MAKEINTRESOURCEA(IDD_USER_VCARD);
- odp.ptszTitle = (hContact != NULL) ? LPGENT("Account") : proto->m_tszUserName;
- odp.dwInitParam = (LPARAM)proto;
+ odp.ptszTitle = (hContact != NULL) ? LPGENT("Account") : m_tszUserName;
+ odp.dwInitParam = (LPARAM)this;
UserInfo_AddPage(wParam, &odp);
}
- if (!lParam && proto->isOnline) {
+ if (!lParam && isOnline) {
CCSDATA ccs = {0};
- proto->GetInfo(0, (LPARAM) &ccs);
+ GetInfo(0, (LPARAM) &ccs);
}
return 0;
}
|