Yingdi Yu | 24ca96f | 2013-10-22 23:42:16 -0700 | [diff] [blame] | 1 | /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil -*- */ |
2 | /* | ||||
3 | * Copyright (c) 2013, Regents of the University of California | ||||
4 | * 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 Yu | 0b0a736 | 2014-08-05 16:31:30 -0700 | [diff] [blame^] | 11 | #ifndef CHRONOS_INVITATION_DIALOG_HPP |
12 | #define CHRONOS_INVITATION_DIALOG_HPP | ||||
Yingdi Yu | 24ca96f | 2013-10-22 23:42:16 -0700 | [diff] [blame] | 13 | |
14 | #include <QDialog> | ||||
15 | |||||
Yingdi Yu | 978b3ae | 2013-10-23 11:50:51 -0700 | [diff] [blame] | 16 | #ifndef Q_MOC_RUN |
Yingdi Yu | 0b0a736 | 2014-08-05 16:31:30 -0700 | [diff] [blame^] | 17 | #include "common.hpp" |
Yingdi Yu | 978b3ae | 2013-10-23 11:50:51 -0700 | [diff] [blame] | 18 | #endif |
19 | |||||
Yingdi Yu | 24ca96f | 2013-10-22 23:42:16 -0700 | [diff] [blame] | 20 | namespace Ui { |
21 | class InvitationDialog; | ||||
22 | } | ||||
23 | |||||
Yingdi Yu | 0b0a736 | 2014-08-05 16:31:30 -0700 | [diff] [blame^] | 24 | namespace chronos{ |
25 | |||||
Yingdi Yu | 24ca96f | 2013-10-22 23:42:16 -0700 | [diff] [blame] | 26 | class InvitationDialog : public QDialog |
27 | { | ||||
28 | Q_OBJECT | ||||
29 | |||||
30 | public: | ||||
Yingdi Yu | 0b0a736 | 2014-08-05 16:31:30 -0700 | [diff] [blame^] | 31 | explicit |
32 | InvitationDialog(QWidget* parent = 0); | ||||
33 | |||||
Yingdi Yu | 24ca96f | 2013-10-22 23:42:16 -0700 | [diff] [blame] | 34 | ~InvitationDialog(); |
35 | |||||
36 | void | ||||
Yingdi Yu | 7989eb2 | 2013-10-31 17:38:22 -0700 | [diff] [blame] | 37 | setInvitation(const std::string& alias, |
Yingdi Yu | 348f5ea | 2014-03-01 14:47:25 -0800 | [diff] [blame] | 38 | const std::string& chatroom, |
Yingdi Yu | fa4ce79 | 2014-02-06 18:09:22 -0800 | [diff] [blame] | 39 | const ndn::Name& invitationInterest); |
Yingdi Yu | 978b3ae | 2013-10-23 11:50:51 -0700 | [diff] [blame] | 40 | |
Yingdi Yu | 24ca96f | 2013-10-22 23:42:16 -0700 | [diff] [blame] | 41 | signals: |
42 | void | ||||
Yingdi Yu | 348f5ea | 2014-03-01 14:47:25 -0800 | [diff] [blame] | 43 | invitationResponded(const ndn::Name& invitationName, bool accepted); |
Yingdi Yu | 24ca96f | 2013-10-22 23:42:16 -0700 | [diff] [blame] | 44 | |
45 | private slots: | ||||
46 | void | ||||
47 | onOkClicked(); | ||||
Yingdi Yu | fa0b6a0 | 2014-04-30 14:26:42 -0700 | [diff] [blame] | 48 | |
Yingdi Yu | 24ca96f | 2013-10-22 23:42:16 -0700 | [diff] [blame] | 49 | void |
50 | onCancelClicked(); | ||||
51 | |||||
52 | |||||
53 | private: | ||||
Yingdi Yu | 0b0a736 | 2014-08-05 16:31:30 -0700 | [diff] [blame^] | 54 | Ui::InvitationDialog* ui; |
Yingdi Yu | fa4ce79 | 2014-02-06 18:09:22 -0800 | [diff] [blame] | 55 | ndn::Name m_invitationInterest; |
Yingdi Yu | 24ca96f | 2013-10-22 23:42:16 -0700 | [diff] [blame] | 56 | }; |
57 | |||||
Yingdi Yu | 0b0a736 | 2014-08-05 16:31:30 -0700 | [diff] [blame^] | 58 | } // namespace chronos |
59 | |||||
60 | #endif // CHRONOS_INVITATION_DIALOG_HPP |