blob: fbebba771790ac3ab3e6b5b9f68e9fcb8ce54d50 [file] [log] [blame]
Edric Milaret2afd2bf2015-07-21 17:12:25 -04001/***************************************************************************
Edric Milaretbab169d2016-01-07 15:13:33 -05002 * Copyright (C) 2015-2016 by Savoir-faire Linux *
Edric Milaret2afd2bf2015-07-21 17:12:25 -04003 * Author: Edric Ladent Milaret <edric.ladent-milaret@savoirfairelinux.com>*
4 * *
5 * This program is free software; you can redistribute it and/or modify *
6 * it under the terms of the GNU General Public License as published by *
7 * the Free Software Foundation; either version 3 of the License, or *
8 * (at your option) any later version. *
9 * *
10 * This program is distributed in the hope that it will be useful, *
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13 * GNU General Public License for more details. *
14 * *
15 * You should have received a copy of the GNU General Public License *
16 * along with this program. If not, see <http://www.gnu.org/licenses/>. *
17 **************************************************************************/
18
Edric Milaret5f316da2015-09-28 11:57:42 -040019#pragma once
Edric Milaret2afd2bf2015-07-21 17:12:25 -040020
21#include <QDialog>
22
23#include "person.h"
24#include "personmodel.h"
25
26namespace Ui {
27class ContactMethodPicker;
28}
29
30class ContactMethodPicker final : public QDialog
31{
32 Q_OBJECT
33
34public:
35 explicit ContactMethodPicker(const Person::ContactMethods &cM, QWidget *parent = 0);
36 ~ContactMethodPicker();
37
38 ContactMethod* getSelected() const;
39
40//UI SLOTS
41private slots:
42 void on_contactMethodListWidget_clicked(const QModelIndex &index);
43
44private:
45 Ui::ContactMethodPicker *ui;
46 const Person::ContactMethods& contactMethods_;
47 int index_;
48};
49