summaryrefslogtreecommitdiff
path: root/protocols/SkypeWeb/src/skype_dialogs.cpp
diff options
context:
space:
mode:
authorMikalaiR <nikolay.romanovich@narod.ru>2015-07-24 14:35:02 +0000
committerMikalaiR <nikolay.romanovich@narod.ru>2015-07-24 14:35:02 +0000
commit6f562987395cad37f8aa55a8950ca86b64f987ad (patch)
treecb02a55d3be21f17275d3a8790a70272ae2e6100 /protocols/SkypeWeb/src/skype_dialogs.cpp
parent6462bedd197e7a1ff6e3aa824c904caff561b04a (diff)
SkypeWeb: ChatCreateDialog refactoring
git-svn-id: http://svn.miranda-ng.org/main/trunk@14678 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/SkypeWeb/src/skype_dialogs.cpp')
-rw-r--r--protocols/SkypeWeb/src/skype_dialogs.cpp15
1 files changed, 12 insertions, 3 deletions
diff --git a/protocols/SkypeWeb/src/skype_dialogs.cpp b/protocols/SkypeWeb/src/skype_dialogs.cpp
index 43834306c8..64a5aae03a 100644
--- a/protocols/SkypeWeb/src/skype_dialogs.cpp
+++ b/protocols/SkypeWeb/src/skype_dialogs.cpp
@@ -45,10 +45,16 @@ void CSkypeInviteDlg::btnOk_OnOk(CCtrlButton*)
//CSkypeGCCreateDlg
CSkypeGCCreateDlg::CSkypeGCCreateDlg(CSkypeProto *proto) :
- CSkypeDlgBase(proto, IDD_GC_CREATE, false), m_ok(this, IDOK), m_cancel(this, IDCANCEL), m_clc(this, IDC_CLIST)
+CSkypeDlgBase(proto, IDD_GC_CREATE, false), m_ok(this, IDOK), m_cancel(this, IDCANCEL), m_clc(this, IDC_CLIST), m_ContactsList(1)
{
m_ok.OnClick = Callback(this, &CSkypeGCCreateDlg::btnOk_OnOk);
}
+CSkypeGCCreateDlg::~CSkypeGCCreateDlg()
+{
+ for (int i = 0; i < m_ContactsList.getCount(); i++)
+ mir_free(m_ContactsList[i]);
+ m_ContactsList.destroy();
+}
void CSkypeGCCreateDlg::OnInitDialog()
{
@@ -70,12 +76,15 @@ void CSkypeGCCreateDlg::btnOk_OnOk(CCtrlButton*)
{
if (m_clc.GetCheck(hItem))
{
- m_hContacts.push_back(hContact);
+ char *szName = db_get_sa(hContact, m_proto->m_szModuleName, SKYPE_SETTINGS_ID);
+ if (szName != NULL)
+ m_ContactsList.insert(szName);
}
}
}
}
- EndDialog(m_hwnd, 1);
+ m_ContactsList.insert(m_proto->m_szSelfSkypeName);
+ EndDialog(m_hwnd, m_ContactsList.getCount());
}
void CSkypeGCCreateDlg::FilterList(CCtrlClc *)