Bitcoin Core  21.99.0
P2P Digital Currency
sendcoinsentry.h
Go to the documentation of this file.
1 // Copyright (c) 2011-2019 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_SENDCOINSENTRY_H
6 #define BITCOIN_QT_SENDCOINSENTRY_H
7 
9 
10 #include <QStackedWidget>
11 
12 class WalletModel;
13 class PlatformStyle;
14 
15 namespace interfaces {
16 class Node;
17 } // namespace interfaces
18 
19 namespace Ui {
20  class SendCoinsEntry;
21 }
22 
28 class SendCoinsEntry : public QStackedWidget
29 {
30  Q_OBJECT
31 
32 public:
33  explicit SendCoinsEntry(const PlatformStyle *platformStyle, QWidget *parent = nullptr);
35 
36  void setModel(WalletModel *model);
39 
41  bool isClear();
42 
43  void setValue(const SendCoinsRecipient &value);
44  void setAddress(const QString &address);
45  void setAmount(const CAmount &amount);
46 
50  QWidget *setupTabChain(QWidget *prev);
51 
52  void setFocus();
53 
54 public Q_SLOTS:
55  void clear();
57 
58 Q_SIGNALS:
59  void removeEntry(SendCoinsEntry *entry);
61  void payAmountChanged();
63 
64 private Q_SLOTS:
65  void deleteClicked();
67  void on_payTo_textChanged(const QString &address);
70  void updateDisplayUnit();
71 
72 private:
74  Ui::SendCoinsEntry *ui;
77 
78  bool updateLabel(const QString &address);
79 };
80 
81 #endif // BITCOIN_QT_SENDCOINSENTRY_H
interfaces
Definition: dummywallet.cpp:10
SendCoinsEntry::setAddress
void setAddress(const QString &address)
Definition: sendcoinsentry.cpp:207
SendCoinsEntry::~SendCoinsEntry
~SendCoinsEntry()
Definition: sendcoinsentry.cpp:55
WalletModel
Interface to Bitcoin wallet from Qt view code.
Definition: walletmodel.h:51
SendCoinsEntry::payAmountChanged
void payAmountChanged()
SendCoinsEntry::setValue
void setValue(const SendCoinsRecipient &value)
Definition: sendcoinsentry.cpp:190
SendCoinsEntry::updateLabel
bool updateLabel(const QString &address)
Definition: sendcoinsentry.cpp:239
SendCoinsEntry::deleteClicked
void deleteClicked()
Definition: sendcoinsentry.cpp:122
SendCoinsEntry::setFocus
void setFocus()
Definition: sendcoinsentry.cpp:223
SendCoinsEntry::setupTabChain
QWidget * setupTabChain(QWidget *prev)
Set up the tab chain manually, as Qt messes up the tab chain by default in some cases (issue https://...
Definition: sendcoinsentry.cpp:178
SendCoinsEntry::ui
Ui::SendCoinsEntry * ui
Definition: sendcoinsentry.h:74
SendCoinsEntry::on_payTo_textChanged
void on_payTo_textChanged(const QString &address)
Definition: sendcoinsentry.cpp:79
SendCoinsEntry::clear
void clear()
Definition: sendcoinsentry.cpp:94
SendCoinsEntry::updateDisplayUnit
void updateDisplayUnit()
Definition: sendcoinsentry.cpp:228
SendCoinsRecipient
Definition: sendcoinsrecipient.h:19
SendCoinsEntry::isClear
bool isClear()
Return whether the entry is still empty and unedited.
Definition: sendcoinsentry.cpp:218
CAmount
int64_t CAmount
Amount in satoshis (Can be negative)
Definition: amount.h:12
SendCoinsEntry::validate
bool validate(interfaces::Node &node)
Definition: sendcoinsentry.cpp:132
SendCoinsEntry::model
WalletModel * model
Definition: sendcoinsentry.h:75
interfaces::Node
Top-level interface for a bitcoin node (bitcoind process).
Definition: node.h:53
SendCoinsEntry::setModel
void setModel(WalletModel *model)
Definition: sendcoinsentry.cpp:84
SendCoinsEntry::useAvailableBalance
void useAvailableBalance(SendCoinsEntry *entry)
Ui
Definition: addressbookpage.h:14
SendCoinsEntry::recipient
SendCoinsRecipient recipient
Definition: sendcoinsentry.h:73
SendCoinsEntry::useAvailableBalanceClicked
void useAvailableBalanceClicked()
Definition: sendcoinsentry.cpp:127
SendCoinsEntry::removeEntry
void removeEntry(SendCoinsEntry *entry)
SendCoinsEntry::SendCoinsEntry
SendCoinsEntry(const PlatformStyle *platformStyle, QWidget *parent=nullptr)
Definition: sendcoinsentry.cpp:22
SendCoinsEntry::checkSubtractFeeFromAmount
void checkSubtractFeeFromAmount()
Definition: sendcoinsentry.cpp:117
node
Definition: interfaces.cpp:66
SendCoinsEntry
A single entry in the dialog for sending bitcoins.
Definition: sendcoinsentry.h:28
SendCoinsEntry::on_addressBookButton_clicked
void on_addressBookButton_clicked()
Definition: sendcoinsentry.cpp:66
SendCoinsEntry::subtractFeeFromAmountChanged
void subtractFeeFromAmountChanged()
SendCoinsEntry::platformStyle
const PlatformStyle * platformStyle
Definition: sendcoinsentry.h:76
SendCoinsEntry::on_pasteButton_clicked
void on_pasteButton_clicked()
Definition: sendcoinsentry.cpp:60
PlatformStyle
Definition: platformstyle.h:13
SendCoinsEntry::setAmount
void setAmount(const CAmount &amount)
Definition: sendcoinsentry.cpp:213
sendcoinsrecipient.h
SendCoinsEntry::getValue
SendCoinsRecipient getValue()
Definition: sendcoinsentry.cpp:167