Somewhat confident now, tested on GNOME+KDE, with all types of transactions. Next...
[novacoin.git] / src / qt / addressbookdialog.h
1 #ifndef ADDRESSBOOKDIALOG_H
2 #define ADDRESSBOOKDIALOG_H
3
4 #include <QDialog>
5
6 namespace Ui {
7     class AddressBookDialog;
8 }
9 class AddressTableModel;
10
11 QT_BEGIN_NAMESPACE
12 class QTableView;
13 QT_END_NAMESPACE
14
15 class AddressBookDialog : public QDialog
16 {
17     Q_OBJECT
18
19 public:
20     explicit AddressBookDialog(QWidget *parent = 0);
21     ~AddressBookDialog();
22
23     enum {
24         SendingTab = 0,
25         ReceivingTab = 1
26     } Tabs;
27
28     void setModel(AddressTableModel *model);
29     void setTab(int tab);
30     const QString &getReturnValue() const { return returnValue; }
31 private:
32     Ui::AddressBookDialog *ui;
33     AddressTableModel *model;
34     QString returnValue;
35
36     QTableView *getCurrentTable();
37
38 private slots:
39     void on_buttonBox_accepted();
40     void on_deleteButton_clicked();
41     void on_tabWidget_currentChanged(int index);
42     void on_newAddressButton_clicked();
43     void on_editButton_clicked();
44     void on_copyToClipboard_clicked();
45 };
46
47 #endif // ADDRESSBOOKDIALOG_H