diff options
author | George Hazan <ghazan@miranda.im> | 2017-12-27 17:19:20 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2017-12-27 17:19:20 +0300 |
commit | e1a3a426a742028570baaee7430b2b5750734e4c (patch) | |
tree | ed801bc7954fcd7c860c506d4f451a8bcb82e39b /src/mir_app/src/auth.cpp | |
parent | 3ae8bfcab00ae1b497b8c1c61d6dcf4bf7322e06 (diff) |
obsolete structure ADDCONTACTSTRUCT, service MS_ADDCONTACT_SHOW and whole m_addcontact.h removed and replaced with Contact_Add* functions
Diffstat (limited to 'src/mir_app/src/auth.cpp')
-rw-r--r-- | src/mir_app/src/auth.cpp | 21 |
1 files changed, 4 insertions, 17 deletions
diff --git a/src/mir_app/src/auth.cpp b/src/mir_app/src/auth.cpp index d80d90bbc2..9c582bcfc6 100644 --- a/src/mir_app/src/auth.cpp +++ b/src/mir_app/src/auth.cpp @@ -143,13 +143,8 @@ public: db_event_get(m_hDbEvent, &dbei); CallProtoService(dbei.szModule, PS_AUTHALLOW, m_hDbEvent, 0); - if (chkAdd.GetState()) { - ADDCONTACTSTRUCT acs = { 0 }; - acs.hDbEvent = m_hDbEvent; - acs.handleType = HANDLE_EVENT; - acs.szProto = ""; - CallService(MS_ADDCONTACT_SHOW, (WPARAM)m_hwnd, (LPARAM)&acs); - } + if (chkAdd.GetState()) + Contact_AddByEvent(m_hDbEvent, m_hwnd); } void onClick_Cancel(CCtrlButton*) @@ -273,20 +268,12 @@ public: void onClick_OK(CCtrlButton*) { - ADDCONTACTSTRUCT acs = { 0 }; - acs.hDbEvent = m_hDbEvent; - acs.handleType = HANDLE_EVENT; - acs.szProto = ""; - CallService(MS_ADDCONTACT_SHOW, (WPARAM)m_hwnd, (LPARAM)&acs); + Contact_AddByEvent(m_hDbEvent, m_hwnd); } void onClick_Add(CCtrlButton*) { - ADDCONTACTSTRUCT acs = { 0 }; - acs.hDbEvent = m_hDbEvent; - acs.handleType = HANDLE_EVENT; - acs.szProto = ""; - CallService(MS_ADDCONTACT_SHOW, (WPARAM)m_hwnd, (LPARAM)&acs); + Contact_AddByEvent(m_hDbEvent, m_hwnd); if (m_hContact == INVALID_CONTACT_ID || !db_get_b(m_hContact, "CList", "NotOnList", 0)) ShowWindow(GetDlgItem(m_hwnd, IDC_ADD), FALSE); |