diff options
Diffstat (limited to 'src/wallet/wallet.h')
-rw-r--r-- | src/wallet/wallet.h | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/src/wallet/wallet.h b/src/wallet/wallet.h index 6ae1c87b1d..1c900b0315 100644 --- a/src/wallet/wallet.h +++ b/src/wallet/wallet.h @@ -3,8 +3,8 @@ // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. -#ifndef BITCOIN_WALLET_H -#define BITCOIN_WALLET_H +#ifndef BITCOIN_WALLET_WALLET_H +#define BITCOIN_WALLET_WALLET_H #include "amount.h" #include "key.h" @@ -455,6 +455,7 @@ private: int64_t nNextResend; int64_t nLastResend; + bool fBroadcastTransactions; /** * Used to keep track of spent outpoints, and @@ -518,6 +519,7 @@ public: nNextResend = 0; nLastResend = 0; nTimeFirstKey = 0; + fBroadcastTransactions = false; } std::map<uint256, CWalletTx> mapWallet; @@ -538,7 +540,7 @@ public: //! check whether we are allowed to upgrade (or already support) to the named feature bool CanSupportFeature(enum WalletFeature wf) { AssertLockHeld(cs_wallet); return nWalletMaxVersion >= wf; } - void AvailableCoins(std::vector<COutput>& vCoins, bool fOnlyConfirmed=true, const CCoinControl *coinControl = NULL) const; + void AvailableCoins(std::vector<COutput>& vCoins, bool fOnlyConfirmed=true, const CCoinControl *coinControl = NULL, bool fIncludeZeroValue=false) const; bool SelectCoinsMinConf(const CAmount& nTargetValue, int nConfMine, int nConfTheirs, std::vector<COutput> vCoins, std::set<std::pair<const CWalletTx*,unsigned int> >& setCoinsRet, CAmount& nValueRet) const; bool IsSpent(const uint256& hash, unsigned int n) const; @@ -723,6 +725,11 @@ public: /** Watch-only address added */ boost::signals2::signal<void (bool fHaveWatchOnly)> NotifyWatchonlyChanged; + + /** Inquire whether this wallet broadcasts transactions. */ + bool GetBroadcastTransactions() const { return fBroadcastTransactions; } + /** Set whether this wallet broadcasts transactions. */ + void SetBroadcastTransactions(bool broadcast) { fBroadcastTransactions = broadcast; } }; /** A key allocated from the key pool. */ @@ -862,4 +869,4 @@ private: std::vector<char> _ssExtra; }; -#endif // BITCOIN_WALLET_H +#endif // BITCOIN_WALLET_WALLET_H |