diff options
author | Cozz Lovan <cozzlovan@yahoo.com> | 2014-07-23 14:34:36 +0200 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2015-03-13 11:04:18 +0100 |
commit | 292623adf59edea52b2927b3d67fd2ff7f997882 (patch) | |
tree | afec21b4e7ff1c2b551b060f5f435895d43d15d6 /src/qt/walletmodel.h | |
parent | 90a43c1e93318584d5443b513c2c0e937acb966a (diff) |
Subtract fee from amount
Fixes #2724 and #1570.
Adds the
automatically-subtract-the-fee-from-the-amount-and-send-whats-left
feature to the GUI and RPC (sendtoaddress,sendmany).
Diffstat (limited to 'src/qt/walletmodel.h')
-rw-r--r-- | src/qt/walletmodel.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/qt/walletmodel.h b/src/qt/walletmodel.h index 4a9a12beaa..de915165f9 100644 --- a/src/qt/walletmodel.h +++ b/src/qt/walletmodel.h @@ -36,9 +36,9 @@ QT_END_NAMESPACE class SendCoinsRecipient { public: - explicit SendCoinsRecipient() : amount(0), nVersion(SendCoinsRecipient::CURRENT_VERSION) { } + explicit SendCoinsRecipient() : amount(0), fSubtractFeeFromAmount(false), nVersion(SendCoinsRecipient::CURRENT_VERSION) { } explicit SendCoinsRecipient(const QString &addr, const QString &label, const CAmount& amount, const QString &message): - address(addr), label(label), amount(amount), message(message), nVersion(SendCoinsRecipient::CURRENT_VERSION) {} + address(addr), label(label), amount(amount), message(message), fSubtractFeeFromAmount(false), nVersion(SendCoinsRecipient::CURRENT_VERSION) {} // If from an unauthenticated payment request, this is used for storing // the addresses, e.g. address-A<br />address-B<br />address-C. @@ -56,6 +56,8 @@ public: // Empty if no authentication or invalid signature/cert/etc. QString authenticatedMerchant; + bool fSubtractFeeFromAmount; // memory only + static const int CURRENT_VERSION = 1; int nVersion; |