Page MenuHomePhabricator

D8006.diff
No OneTemporary

D8006.diff

diff --git a/src/qt/createwalletdialog.h b/src/qt/createwalletdialog.h
--- a/src/qt/createwalletdialog.h
+++ b/src/qt/createwalletdialog.h
@@ -24,9 +24,9 @@
virtual ~CreateWalletDialog();
QString walletName() const;
- bool encrypt() const;
- bool disablePrivateKeys() const;
- bool blank() const;
+ bool isEncryptWalletChecked() const;
+ bool isDisablePrivateKeysChecked() const;
+ bool isMakeBlankWalletChecked() const;
private:
Ui::CreateWalletDialog *ui;
diff --git a/src/qt/createwalletdialog.cpp b/src/qt/createwalletdialog.cpp
--- a/src/qt/createwalletdialog.cpp
+++ b/src/qt/createwalletdialog.cpp
@@ -26,8 +26,9 @@
connect(ui->encrypt_wallet_checkbox, &QCheckBox::toggled,
[this](bool checked) {
- // Disable disable_privkeys_checkbox when encrypt is set to
- // true, enable it when encrypt is false
+ // Disable disable_privkeys_checkbox when
+ // isEncryptWalletChecked is set to true, enable it when
+ // encrypt is false
ui->disable_privkeys_checkbox->setEnabled(!checked);
// When the disable_privkeys_checkbox is disabled, uncheck it.
@@ -45,14 +46,14 @@
return ui->wallet_name_line_edit->text();
}
-bool CreateWalletDialog::encrypt() const {
+bool CreateWalletDialog::isEncryptWalletChecked() const {
return ui->encrypt_wallet_checkbox->isChecked();
}
-bool CreateWalletDialog::disablePrivateKeys() const {
+bool CreateWalletDialog::isDisablePrivateKeysChecked() const {
return ui->disable_privkeys_checkbox->isChecked();
}
-bool CreateWalletDialog::blank() const {
+bool CreateWalletDialog::isMakeBlankWalletChecked() const {
return ui->blank_wallet_checkbox->isChecked();
}
diff --git a/src/qt/walletcontroller.cpp b/src/qt/walletcontroller.cpp
--- a/src/qt/walletcontroller.cpp
+++ b/src/qt/walletcontroller.cpp
@@ -214,10 +214,10 @@
std::string name = m_create_wallet_dialog->walletName().toStdString();
uint64_t flags = 0;
- if (m_create_wallet_dialog->disablePrivateKeys()) {
+ if (m_create_wallet_dialog->isDisablePrivateKeysChecked()) {
flags |= WALLET_FLAG_DISABLE_PRIVATE_KEYS;
}
- if (m_create_wallet_dialog->blank()) {
+ if (m_create_wallet_dialog->isMakeBlankWalletChecked()) {
flags |= WALLET_FLAG_BLANK_WALLET;
}
@@ -266,7 +266,7 @@
connect(m_create_wallet_dialog, &QDialog::rejected,
[this] { Q_EMIT finished(); });
connect(m_create_wallet_dialog, &QDialog::accepted, [this] {
- if (m_create_wallet_dialog->encrypt()) {
+ if (m_create_wallet_dialog->isEncryptWalletChecked()) {
askPassphrase();
} else {
createWallet();

File Metadata

Mime Type
text/plain
Expires
Sat, Mar 1, 11:17 (19 h, 41 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
5187556
Default Alt Text
D8006.diff (2 KB)

Event Timeline