PasswordDialog: UI improvements

This commit is contained in:
tobtoht
2022-05-27 11:49:32 +02:00
parent 6633353bf3
commit ef5f831013
4 changed files with 14 additions and 6 deletions
+3 -3
View File
@@ -1627,15 +1627,15 @@ void MainWindow::updateRecentlyOpenedMenu() {
}
bool MainWindow::verifyPassword() {
bool ok;
bool incorrectPassword = false;
while (true) {
PasswordDialog passwordDialog{this->walletName(), false, this};
PasswordDialog passwordDialog{this->walletName(), incorrectPassword, true, this};
int ret = passwordDialog.exec();
if (ret == QDialog::Rejected) {
return false;
}
if (passwordDialog.password != m_ctx->wallet->getPassword()) {
QMessageBox::warning(this, "Error", "Incorrect password");
incorrectPassword = true;
continue;
}
break;