Dash Core Source Documentation (0.16.0.1)

Find detailed information regarding the Dash Core source code.

walletview.h
Go to the documentation of this file.
1 // Copyright (c) 2011-2015 The Bitcoin Core developers
2 // Distributed under the MIT software license, see the accompanying
3 // file COPYING or http://www.opensource.org/licenses/mit-license.php.
4 
5 #ifndef BITCOIN_QT_WALLETVIEW_H
6 #define BITCOIN_QT_WALLETVIEW_H
7 
8 #include <amount.h>
9 #include <qt/masternodelist.h>
10 
11 #include <QStackedWidget>
12 
13 class BitcoinGUI;
14 class ClientModel;
15 class OverviewPage;
16 class ReceiveCoinsDialog;
17 class SendCoinsDialog;
18 class SendCoinsRecipient;
19 class TransactionView;
20 class WalletModel;
21 class AddressBookPage;
22 
23 QT_BEGIN_NAMESPACE
24 class QLabel;
25 class QModelIndex;
26 class QProgressDialog;
27 QT_END_NAMESPACE
28 
29 /*
30  WalletView class. This class represents the view to a single wallet.
31  It was added to support multiple wallet functionality. Each wallet gets its own WalletView instance.
32  It communicates with both the client and the wallet models to give the user an up-to-date view of the
33  current core state.
34 */
35 class WalletView : public QStackedWidget
36 {
37  Q_OBJECT
38 
39 public:
40  explicit WalletView(QWidget* parent);
41  ~WalletView();
42 
43  void setBitcoinGUI(BitcoinGUI *gui);
54 
55  bool handlePaymentRequest(const SendCoinsRecipient& recipient);
56 
57  void showOutOfSyncWarning(bool fShow);
58 
59 private:
62 
64  QWidget *transactionsPage;
71 
73 
74  QProgressDialog *progressDialog;
75  QLabel *transactionSum;
76 
77 public Q_SLOTS:
79  void gotoOverviewPage();
81  void gotoHistoryPage();
83  void gotoMasternodePage();
85  void gotoReceiveCoinsPage();
87  void gotoSendCoinsPage(QString addr = "");
89  void gotoPrivateSendCoinsPage(QString addr = "");
90 
92  void gotoSignMessageTab(QString addr = "");
94  void gotoVerifyMessageTab(QString addr = "");
95 
100  void processNewTransaction(const QModelIndex& parent, int start, int /*end*/);
102  void encryptWallet(bool status);
104  void backupWallet();
106  void changePassphrase();
108  void unlockWallet(bool fAnonymizeOnly=false);
110  void lockWallet();
111 
113  void usedSendingAddresses();
115  void usedReceivingAddresses();
116 
118  void updateEncryptionStatus();
119 
121  void showProgress(const QString &title, int nProgress);
122 
125 
126 
128  void trxAmount(QString amount);
129 Q_SIGNALS:
131  void showNormalIfMinimized();
133  void message(const QString &title, const QString &message, unsigned int style);
135  void encryptionStatusChanged(int status);
137  void hdEnabledStatusChanged(int hdEnabled);
139  void incomingTransaction(const QString& date, int unit, const CAmount& amount, const QString& type, const QString& address, const QString& label);
142 };
143 
144 #endif // BITCOIN_QT_WALLETVIEW_H
QWidget * transactionsPage
Definition: walletview.h:64
void trxAmount(QString amount)
Update selected DASH amount from transactionview.
Definition: walletview.cpp:406
Dialog for requesting payment of bitcoins.
void unlockWallet(bool fAnonymizeOnly=false)
Ask for passphrase to unlock wallet temporarily.
Definition: walletview.cpp:339
void gotoVerifyMessageTab(QString addr="")
Show Sign/Verify Message dialog and switch to verify message tab.
Definition: walletview.cpp:275
OverviewPage * overviewPage
Definition: walletview.h:63
TransactionView * transactionView
Definition: walletview.h:72
void usedSendingAddresses()
Show used sending addresses.
Definition: walletview.cpp:361
void changePassphrase()
Change encrypted wallet passphrase.
Definition: walletview.cpp:332
ClientModel * clientModel
Definition: walletview.h:60
WalletView(QWidget *parent)
Definition: walletview.cpp:34
void requestedSyncWarningInfo()
User has requested more information about the out of sync state.
Definition: walletview.cpp:400
WalletModel * walletModel
Definition: walletview.h:61
void outOfSyncWarningClicked()
Notify that the out of sync warning icon has been pressed.
Bitcoin GUI main class.
Definition: bitcoingui.h:49
void gotoSendCoinsPage(QString addr="")
Switch to send coins page.
Definition: walletview.cpp:246
void updateEncryptionStatus()
Re-emit encryption status signal.
Definition: walletview.cpp:297
void processNewTransaction(const QModelIndex &parent, int start, int)
Show incoming transaction notification for new transactions.
Definition: walletview.cpp:194
SendCoinsDialog * sendCoinsPage
Definition: walletview.h:66
int64_t CAmount
Amount in satoshis (Can be negative)
Definition: amount.h:12
WalletModel * getWalletModel()
Definition: walletview.h:48
void hdEnabledStatusChanged(int hdEnabled)
HD-Enabled status of wallet changed (only possible during startup)
void gotoHistoryPage()
Switch to history (transactions) page.
Definition: walletview.cpp:228
void setBitcoinGUI(BitcoinGUI *gui)
Definition: walletview.cpp:119
void usedReceivingAddresses()
Show used receiving addresses.
Definition: walletview.cpp:369
void setWalletModel(WalletModel *walletModel)
Set the wallet model.
Definition: walletview.cpp:153
SendCoinsDialog * privateSendCoinsPage
Definition: walletview.h:67
void encryptionStatusChanged(int status)
Encryption status of wallet changed.
void incomingTransaction(const QString &date, int unit, const CAmount &amount, const QString &type, const QString &address, const QString &label)
Notify that a new transaction appeared.
Widget showing the transaction list for a wallet, including a filter row.
void message(const QString &title, const QString &message, unsigned int style)
Fired when a message should be reported to the user.
Dialog for sending bitcoins.
Widget that shows a list of sending or receiving addresses.
Model for Dash network client.
Definition: clientmodel.h:42
void showNormalIfMinimized()
Signal that we want to show the main window.
Masternode Manager page widget.
void backupWallet()
Backup the wallet.
Definition: walletview.cpp:313
bool handlePaymentRequest(const SendCoinsRecipient &recipient)
Definition: walletview.cpp:287
QLabel * transactionSum
Definition: walletview.h:75
void gotoOverviewPage()
Switch to overview (home) page.
Definition: walletview.cpp:223
AddressBookPage * usedSendingAddressesPage
Definition: walletview.h:68
void gotoPrivateSendCoinsPage(QString addr="")
Switch to PrivateSend coins page.
Definition: walletview.cpp:255
void gotoSignMessageTab(QString addr="")
Show Sign/Verify Message dialog and switch to sign message tab.
Definition: walletview.cpp:263
Interface to Bitcoin wallet from Qt view code.
Definition: walletmodel.h:100
void showProgress(const QString &title, int nProgress)
Show progress dialog e.g.
Definition: walletview.cpp:377
MasternodeList * masternodeListPage
Definition: walletview.h:70
void lockWallet()
Lock wallet.
Definition: walletview.cpp:353
void setClientModel(ClientModel *clientModel)
Set the client model.
Definition: walletview.cpp:140
void encryptWallet(bool status)
Encrypt the wallet.
Definition: walletview.cpp:302
void gotoMasternodePage()
Switch to masternode page.
Definition: walletview.cpp:233
ReceiveCoinsDialog * receiveCoinsPage
Definition: walletview.h:65
void gotoReceiveCoinsPage()
Switch to receive coins page.
Definition: walletview.cpp:241
Overview ("home") page widget.
Definition: overviewpage.h:27
void showOutOfSyncWarning(bool fShow)
Definition: walletview.cpp:292
QProgressDialog * progressDialog
Definition: walletview.h:74
AddressBookPage * usedReceivingAddressesPage
Definition: walletview.h:69
Released under the MIT license