fix: Update-Ladebalken erreicht jetzt sichtbar 100%
All checks were successful
Build AppImage / build (push) Successful in 7m53s

- Backend: Finales 100%-Progress-Event nach Download-Loop senden
- Frontend: Explizit auf 100% setzen + 600ms Pause vor Bestätigungsdialog
- Behebt visuellen Bug dass Balken bei ~97% stehen blieb

[appimage]

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Eddy 2026-04-21 09:11:34 +02:00
parent f94cfc287e
commit 98dca27ebe
2 changed files with 11 additions and 0 deletions

View file

@ -357,6 +357,14 @@ pub async fn download_update(
app.emit("update-progress", &progress).ok(); app.emit("update-progress", &progress).ok();
} }
// Finales 100%-Event senden damit die UI den Balken voll anzeigt
let final_progress = DownloadProgress {
downloaded,
total: if total_size > 0 { total_size } else { downloaded },
percent: 100.0,
};
app.emit("update-progress", &final_progress).ok();
// SHA256 verifizieren (wenn erwartet) // SHA256 verifizieren (wenn erwartet)
if let Some(expected) = expected_sha256 { if let Some(expected) = expected_sha256 {
let actual = format!("{:x}", hasher.finalize()); let actual = format!("{:x}", hasher.finalize());

View file

@ -125,6 +125,9 @@
expectedSha256: updateInfo.sha256, expectedSha256: updateInfo.sha256,
}); });
console.log('Download abgeschlossen:', downloadedPath); console.log('Download abgeschlossen:', downloadedPath);
// Balken auf 100% setzen und kurz anzeigen bevor Bestätigung kommt
progress = { downloaded: progress?.total || 0, total: progress?.total || 0, percent: 100 };
await new Promise(r => setTimeout(r, 600));
// NICHT sofort installieren — User-Bestätigung abwarten // NICHT sofort installieren — User-Bestätigung abwarten
downloading = false; downloading = false;
awaitingConfirmation = true; awaitingConfirmation = true;