Raven Core  3.0.0
P2P Digital Currency
editaddressdialog.h
Go to the documentation of this file.
1 // Copyright (c) 2011-2015 The Bitcoin Core developers
2 // Copyright (c) 2017-2019 The Raven Core developers
3 // Distributed under the MIT software license, see the accompanying
4 // file COPYING or http://www.opensource.org/licenses/mit-license.php.
5 
6 #ifndef RAVEN_QT_EDITADDRESSDIALOG_H
7 #define RAVEN_QT_EDITADDRESSDIALOG_H
8 
9 #include <QDialog>
10 
11 class AddressTableModel;
12 
13 namespace Ui {
14  class EditAddressDialog;
15 }
16 
17 QT_BEGIN_NAMESPACE
18 class QDataWidgetMapper;
19 QT_END_NAMESPACE
20 
23 class EditAddressDialog : public QDialog
24 {
25  Q_OBJECT
26 
27 public:
28  enum Mode {
32  EditSendingAddress
33  };
34 
35  explicit EditAddressDialog(Mode mode, QWidget *parent);
37 
38  void setModel(AddressTableModel *model);
39  void loadRow(int row);
40 
41  QString getAddress() const;
42  void setAddress(const QString &address);
43 
44 public Q_SLOTS:
45  void accept();
46 
47 private:
48  bool saveCurrentRow();
49 
50  Ui::EditAddressDialog *ui;
51  QDataWidgetMapper *mapper;
54 
55  QString address;
56 };
57 
58 #endif // RAVEN_QT_EDITADDRESSDIALOG_H
QDataWidgetMapper * mapper
Qt model of the address book in the core.
AddressTableModel * model
Dialog for editing an address and associated information.
Ui::EditAddressDialog * ui