blob: 78d949d46b8207bc77203c14c2a8d2d86af2c59a [file] [log] [blame]
Yingdi Yu0a6b6c52013-10-15 17:54:00 -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
11#ifndef PROFILEEDITOR_H
12#define PROFILEEDITOR_H
13
14#include <QDialog>
15#include <QtSql/QSqlTableModel>
16
17#ifndef Q_MOC_RUN
18#include "contact-storage.h"
19#endif
20
21namespace Ui {
22class ProfileEditor;
23}
24
25class ProfileEditor : public QDialog
26{
27 Q_OBJECT
28
29public:
Yingdi Yuc26af3c2013-10-17 17:03:46 -070030 explicit ProfileEditor(ndn::Ptr<ContactStorage> contactStorage,
31 QWidget *parent = 0);
Yingdi Yu0a6b6c52013-10-15 17:54:00 -070032
33 ~ProfileEditor();
34
35private slots:
36 void
37 onAddClicked();
38
39 void
40 onDeleteClicked();
41
42 void
43 onOkClicked();
44
Yingdi Yuc26af3c2013-10-17 17:03:46 -070045 void
46 onGetClicked();
47
Yingdi Yu0a6b6c52013-10-15 17:54:00 -070048
49private:
50 Ui::ProfileEditor *ui;
51 QSqlTableModel* m_tableModel;
52 ndn::Ptr<ContactStorage> m_contactStorage;
Yingdi Yuc26af3c2013-10-17 17:03:46 -070053 ndn::Name m_defaultIdentity;
54 ndn::Name m_currentIdentity;
Yingdi Yu0a6b6c52013-10-15 17:54:00 -070055};
56
57#endif // PROFILEEDITOR_H