blob: ee2561c574e147290cbd94948d412393fb72b6e3 [file] [log] [blame]
Yingdi Yu348f5ea2014-03-01 14:47:25 -08001/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil -*- */
2/*
Varun Patila24bd3e2020-11-24 10:08:33 +05303 * Copyright (c) 2020, Regents of the University of California
Yingdi Yu348f5ea2014-03-01 14:47:25 -08004 * Yingdi Yu
5 *
6 * BSD license, See the LICENSE file for more information
7 *
8 * Author: Yingdi Yu <yingdi@cs.ucla.edu>
9 */
10
Yingdi Yueb692ac2015-02-10 18:46:18 -080011#ifndef CHRONOCHAT_INVITE_LIST_DIALOG_HPP
12#define CHRONOCHAT_INVITE_LIST_DIALOG_HPP
Yingdi Yu348f5ea2014-03-01 14:47:25 -080013
14#include <QDialog>
15#include <QStringListModel>
16
Yingdi Yu348f5ea2014-03-01 14:47:25 -080017namespace Ui {
18class InviteListDialog;
Varun Patila24bd3e2020-11-24 10:08:33 +053019} // namespace Ui
Yingdi Yu348f5ea2014-03-01 14:47:25 -080020
Yingdi Yueb692ac2015-02-10 18:46:18 -080021namespace chronochat {
Yingdi Yu0b0a7362014-08-05 16:31:30 -070022
Yingdi Yu348f5ea2014-03-01 14:47:25 -080023class InviteListDialog : public QDialog
24{
25 Q_OBJECT
26
27public:
28 explicit
Yingdi Yu0b0a7362014-08-05 16:31:30 -070029 InviteListDialog(QWidget* parent = 0);
Yingdi Yufa0b6a02014-04-30 14:26:42 -070030
Yingdi Yu348f5ea2014-03-01 14:47:25 -080031 ~InviteListDialog();
32
33 void
34 setInviteLabel(std::string label);
Yingdi Yufa0b6a02014-04-30 14:26:42 -070035
Yingdi Yu348f5ea2014-03-01 14:47:25 -080036signals:
37 void
38 sendInvitation(const QString&);
39
40public slots:
41 void
42 onContactAliasListReady(const QStringList& aliasList);
43
44 void
45 onContactIdListReady(const QStringList& idList);
46
47private slots:
Yingdi Yufa0b6a02014-04-30 14:26:42 -070048 void
Yingdi Yu348f5ea2014-03-01 14:47:25 -080049 onInviteClicked();
50
51 void
52 onCancelClicked();
53
54private:
Yingdi Yu0b0a7362014-08-05 16:31:30 -070055 Ui::InviteListDialog* ui;
Yingdi Yu348f5ea2014-03-01 14:47:25 -080056 QStringListModel* m_contactListModel;
57 QStringList m_contactAliasList;
58 QStringList m_contactIdList;
59};
60
Yingdi Yueb692ac2015-02-10 18:46:18 -080061} // namespace chronochat
Yingdi Yu0b0a7362014-08-05 16:31:30 -070062
Yingdi Yueb692ac2015-02-10 18:46:18 -080063#endif // CHRONOCHAT_INVITE_LIST_DIALOG_HPP