|
|
@ -1290,9 +1290,18 @@ void MainWindow::importPrivKey() { |
|
|
|
delete multiline; |
|
|
|
} |
|
|
|
|
|
|
|
//TODO: if rescan is not checked, disable the rescan height input
|
|
|
|
bool rescan = pui.chkrescan->isChecked(); |
|
|
|
|
|
|
|
//TODO: if rescan is not checked, disable the rescan height input
|
|
|
|
// Why don't these work?
|
|
|
|
if (rescan) { |
|
|
|
//pui.rescanfrom->setEnabled(true);
|
|
|
|
pui.rescanfrom->setReadOnly(false); |
|
|
|
} else { |
|
|
|
//pui.rescanfrom->setDisabled(true);
|
|
|
|
pui.rescanfrom->setReadOnly(true); |
|
|
|
} |
|
|
|
|
|
|
|
// Start the import. The function takes ownership of keys
|
|
|
|
QTimer::singleShot(1, [=]() { |
|
|
|
// we import all keys without rescanning and then finally decide if we will rescan once
|
|
|
@ -1300,7 +1309,7 @@ void MainWindow::importPrivKey() { |
|
|
|
|
|
|
|
if (rescan) { |
|
|
|
rpc->rescan(pui.rescanfrom->text().toInt() , [=] (QJsonValue response){ |
|
|
|
qDebug() << __func__ << ":rescanning from height " << pui.rescanfrom << " finished" << response; |
|
|
|
qDebug() << __func__ << ":rescanning from height " << pui.rescanfrom->text().toInt() << " finished" << response; |
|
|
|
ui->statusBar->showMessage(tr("Rescanning finished"), 5000); |
|
|
|
}); |
|
|
|
} |
|
|
|