Yingdi Yu | 3b318c1 | 2013-10-15 17:54:00 -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 | |
| 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 | |
| 21 | namespace Ui { |
| 22 | class ProfileEditor; |
| 23 | } |
| 24 | |
| 25 | class ProfileEditor : public QDialog |
| 26 | { |
| 27 | Q_OBJECT |
| 28 | |
| 29 | public: |
| 30 | explicit ProfileEditor(ndn::Ptr<ContactStorage> contactStorage, QWidget *parent = 0); |
| 31 | |
| 32 | ~ProfileEditor(); |
| 33 | |
| 34 | private slots: |
| 35 | void |
| 36 | onAddClicked(); |
| 37 | |
| 38 | void |
| 39 | onDeleteClicked(); |
| 40 | |
| 41 | void |
| 42 | onOkClicked(); |
| 43 | |
| 44 | |
| 45 | private: |
| 46 | Ui::ProfileEditor *ui; |
| 47 | QSqlTableModel* m_tableModel; |
| 48 | ndn::Ptr<ContactStorage> m_contactStorage; |
| 49 | }; |
| 50 | |
| 51 | #endif // PROFILEEDITOR_H |