mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-11 06:28:31 +01:00
refactor: Get rid of Wallet::IsWalletFlagSet method
Replace by privateKeysDisabled method to avoid need for GUI to reference internal wallet flags. Also remove adjacent WalletModel canGetAddresses wrapper that serves no purpose and make Wallet::canGetAddresses non-const so it can be implemented by IPC classes in #10102.
This commit is contained in:
@@ -463,8 +463,8 @@ public:
|
||||
}
|
||||
unsigned int getConfirmTarget() override { return m_wallet->m_confirm_target; }
|
||||
bool hdEnabled() override { return m_wallet->IsHDEnabled(); }
|
||||
bool canGetAddresses() const override { return m_wallet->CanGetAddresses(); }
|
||||
bool IsWalletFlagSet(uint64_t flag) override { return m_wallet->IsWalletFlagSet(flag); }
|
||||
bool canGetAddresses() override { return m_wallet->CanGetAddresses(); }
|
||||
bool privateKeysDisabled() override { return m_wallet->IsWalletFlagSet(WALLET_FLAG_DISABLE_PRIVATE_KEYS); }
|
||||
OutputType getDefaultAddressType() override { return m_wallet->m_default_address_type; }
|
||||
OutputType getDefaultChangeType() override { return m_wallet->m_default_change_type; }
|
||||
CAmount getDefaultMaxTxFee() override { return m_wallet->m_default_max_tx_fee; }
|
||||
|
||||
@@ -247,10 +247,10 @@ public:
|
||||
virtual bool hdEnabled() = 0;
|
||||
|
||||
// Return whether the wallet is blank.
|
||||
virtual bool canGetAddresses() const = 0;
|
||||
virtual bool canGetAddresses() = 0;
|
||||
|
||||
// check if a certain wallet flag is set.
|
||||
virtual bool IsWalletFlagSet(uint64_t flag) = 0;
|
||||
// Return whether private keys enabled.
|
||||
virtual bool privateKeysDisabled() = 0;
|
||||
|
||||
// Get default address type.
|
||||
virtual OutputType getDefaultAddressType() = 0;
|
||||
|
||||
Reference in New Issue
Block a user