fix(ui): finish a stranded bootstrap even when its dialog is closed
A Settings bootstrap was only wrapped up inside the dialog's own draw path. If the dialog finished downloading, verifying or extracting while the user had clicked away or minimized the window, completion was never processed: the connect and reconcile gate stayed held and the post-bootstrap rescan was never armed. - Completion is now a pure decision driven from a pump() that both the per-frame update and the dialog's render call, so a finished bootstrap is handled every tick whether or not the dialog is drawn. - With the dialog open the behaviour is unchanged: it advances to the Done or Failed screen and those screens still own the gate. With the dialog closed, pump() releases the gate itself and shows a success or failure toast; a user-cancelled run is released silently. User-visible: a bootstrap started from Settings now completes, arms its rescan and reports its result even if the dialog is closed or the window is minimized when it finishes. Tests: the completion decision for an unfinished worker, a completed run with the dialog open and closed, a failed run, and a user-cancelled run. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -1518,6 +1518,10 @@ void App::update()
|
||||
// C210: the "Keep in each address" consolidation run, if one is going (paced; one RPC at a time).
|
||||
pumpConsolidation();
|
||||
|
||||
// A Settings bootstrap that finished while its dialog wasn't drawn (clicked away, minimized): process it
|
||||
// here so the connect and reconcile gates release and the post-bootstrap rescan is armed.
|
||||
ui::BootstrapDownloadDialog::pump();
|
||||
|
||||
// After a bootstrap the preserved wallet.dat has stale spent-state and must be reconciled
|
||||
// against the freshly-imported chain, or the first send tries to spend already-spent notes and
|
||||
// is rejected. The -rescan restart can't do it (the snapshot lacks pre-snapshot blocks), so we
|
||||
|
||||
Reference in New Issue
Block a user