[Qt] Disable creating receive addresses when private keys are disabled

This commit is contained in:
Jonas Schnelli
2017-02-01 13:54:28 +01:00
parent 2f15c2bc20
commit c7b8f343e9
5 changed files with 13 additions and 0 deletions

View File

@@ -558,6 +558,11 @@ bool WalletModel::isWalletEnabled()
return !gArgs.GetBoolArg("-disablewallet", DEFAULT_DISABLE_WALLET);
}
bool WalletModel::privateKeysDisabled() const
{
return m_wallet->IsWalletFlagSet(WALLET_FLAG_DISABLE_PRIVATE_KEYS);
}
QString WalletModel::getWalletName() const
{
return QString::fromStdString(m_wallet->getWalletName());