diff --git a/src/core/account_runtime.rs b/src/core/account_runtime.rs index 1b8ccbc..bf73ae6 100644 --- a/src/core/account_runtime.rs +++ b/src/core/account_runtime.rs @@ -330,6 +330,13 @@ impl FolderRuntime { // cannot repaint the row. let run_active = std::rc::Rc::new(std::cell::Cell::new(false)); self.scheduler.set_run_active(run_active.clone()); + // Issue #148: startup syncs begin before connect_progress() wires the + // forwarder, so the flag would stay false for the entire first run and + // the UI would show no per-file progress. Seed it from the scheduler + // state when connecting, so an in-flight run keeps emitting events. + if self.scheduler.is_running() { + run_active.set(true); + } glib::spawn_future_local(async move { while let Ok(progress) = progress_rx.recv().await { if !run_active.get() { diff --git a/src/ui/folder_status.rs b/src/ui/folder_status.rs index 2bc415d..0fd967e 100644 --- a/src/ui/folder_status.rs +++ b/src/ui/folder_status.rs @@ -396,6 +396,7 @@ impl FolderStatusRow { let spinner = this.spinner.clone(); let progress_bar = this.progress_bar.clone(); let row = this.row.clone(); + let slot = this.slot.clone(); let remote_path = this.remote_path.clone(); let format_last_sync = this.format_last_sync.clone(); let subscription = controller.subscribe(move |snapshot: &StateSnapshot| { @@ -408,6 +409,11 @@ impl FolderStatusRow { format_last_sync.as_ref().map(|f| f()), snapshot, ); + // Issue #150: GTK may not repaint the row when properties + // are updated from a subscription callback. Force a redraw + // of the whole slot so state, spinner, bar and caption all + // update together. + slot.queue_draw(); }); this._subscription = Some(subscription); // Live per-file progress (issue #86). Only the widgets are @@ -422,8 +428,12 @@ impl FolderStatusRow { .unwrap_or_else(|| progress.path.clone()); progress_label.set_text(&progress_line_text(progress, &file)); progress_label.set_visible(true); + progress_label.queue_draw(); + } + _ => { + progress_label.set_visible(false); + progress_label.queue_draw(); } - _ => progress_label.set_visible(false), }); this._progress_subscription = Some(progress_subscription); }