blob: dc43de69b7e7307e3e2061d850708e412d5f0e28 [file] [log] [blame]
Yingdi Yu2ac40fb2013-10-21 13:38:38 -07001/* -*- 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 Yu0b0a7362014-08-05 16:31:30 -070011#ifndef CHRONOS_SET_ALIAS_DIALOG_HPP
12#define CHRONOS_SET_ALIAS_DIALOG_HPP
Yingdi Yu2ac40fb2013-10-21 13:38:38 -070013
14#include <QDialog>
15
16#ifndef Q_MOC_RUN
Yingdi Yufa0b6a02014-04-30 14:26:42 -070017#include <ndn-cxx/name.hpp>
Yingdi Yu2ac40fb2013-10-21 13:38:38 -070018#endif
19
20namespace Ui {
21class SetAliasDialog;
22}
23
Yingdi Yu0b0a7362014-08-05 16:31:30 -070024namespace chronos {
25
Yingdi Yu2ac40fb2013-10-21 13:38:38 -070026class SetAliasDialog : public QDialog
27{
28 Q_OBJECT
29
30public:
Yingdi Yufa0b6a02014-04-30 14:26:42 -070031 explicit
Yingdi Yu0b0a7362014-08-05 16:31:30 -070032 SetAliasDialog(QWidget* parent = 0);
Yingdi Yu348f5ea2014-03-01 14:47:25 -080033
Yingdi Yu2ac40fb2013-10-21 13:38:38 -070034 ~SetAliasDialog();
35
36 void
Yingdi Yu348f5ea2014-03-01 14:47:25 -080037 setTargetIdentity(const QString& targetIdentity, const QString& alias);
Yingdi Yu2ac40fb2013-10-21 13:38:38 -070038
39signals:
40 void
Yingdi Yu348f5ea2014-03-01 14:47:25 -080041 aliasChanged(const QString& identity, const QString& alias);
Yingdi Yu2ac40fb2013-10-21 13:38:38 -070042
43private slots:
44 void
45 onOkClicked();
46
Yingdi Yufa0b6a02014-04-30 14:26:42 -070047 void
Yingdi Yu2ac40fb2013-10-21 13:38:38 -070048 onCancelClicked();
49
50private:
Yingdi Yu0b0a7362014-08-05 16:31:30 -070051 Ui::SetAliasDialog* ui;
Yingdi Yu348f5ea2014-03-01 14:47:25 -080052 QString m_targetIdentity;
Yingdi Yu2ac40fb2013-10-21 13:38:38 -070053};
54
Yingdi Yu0b0a7362014-08-05 16:31:30 -070055} // namespace chronos
56
57#endif // CHRONOS_SET_ALIAS_DIALOG_HPP