Skip to content

fix(desktop-gpui): refresh every library view and the tray after deleting a recording - #3063

Merged
richiemcilroy merged 3 commits into
CapSoftware:mainfrom
yashranaway:fix/gpui-delete-refresh
Oct 24, 2026
Merged

richiemcilroy merged 3 commits into
CapSoftware:mainfrom
yashranaway:fix/gpui-delete-refresh

Conversation

@yashranaway

@yashranaway yashranaway commented Oct 24, 2026 •

Copy link
Copy Markdown
Contributor

deleting a recording from the main window or from settings only refreshed that one window's list. the other window kept showing it, and the tray's previous recordings menu never refreshed at all, so it still listed the deleted recording until something else rebuilt it. the tauri app refreshed the tray on every delete.

both delete paths now go through the same helper the editor delete already uses, which refreshes main and settings, and that helper now also refreshes the tray. the tray is a no-op stub on linux so i couldn't exercise the menu itself here, only that the existing delete tests still pass.

RetriggerView in GreptileConfidence Score: 5/5

The PR appears safe to merge; both earlier findings are addressed.

Summary

Recording deletion now refreshes both library windows and the tray through one shared helper.

  • Deleting a recording refreshes both library views and the tray menu.

Reviews (2) · Last reviewed commit: "fix(desktop-gpui): defer the library ref..." · Reviewed by Greptile

@vercel

vercel Bot commented Oct 24, 2026

Copy link
Copy Markdown
Contributor

@yashranaway is attempting to deploy a commit to the Cap Software Inc Team on Vercel.

A member of the Team first needs to authorize it.

Comment thread apps/desktop-gpui/src/main_window.rs Outdated
Comment thread apps/desktop-gpui/src/app_windows.rs
@richiemcilroy

Copy link
Copy Markdown
Member

Thanks for this. Two issues:

  1. Both delete paths now call refresh_library_after_delete from inside cx.update on the spawn_in window context. That update already holds the window that started the delete, so the helper's main.update(...) / settings.update(...) for that same window fails and the error is dropped by .ok(). The list you deleted from no longer refreshes. Please run the shared refresh after the window update ends, e.g. cx.update(|_, cx| cx.defer(app_windows::refresh_library_after_delete)), and check both the main window and settings paths.
  2. Adding tray::refresh_previous inside refresh_library_after_delete makes existing callers scan the tray's recent recordings twice: the studio thumbnail event handler in app_windows.rs calls refresh_previous right before the helper, and import::refresh_libraries calls it right after. Each call starts a background scan. Please either remove those now-redundant calls, or leave the helper alone and call refresh_previous from the delete paths only (main window, settings and the editor delete).

Once those are in, we'll re-run the Greptile review. It needs a 5/5 plus green CI to merge.

@yashranaway

Copy link
Copy Markdown
Contributor Author

@greptileai review

@yashranaway

Copy link
Copy Markdown
Contributor Author

@richiemcilroy both done in 052fab6. the main window and settings delete paths now run the shared refresh through cx.defer, so the window that started the delete refreshes too. i kept tray::refresh_previous in the helper and removed the now-redundant calls in the studio thumbnail handler and import::refresh_libraries, so each path scans once. greptile is 5/5.

@richiemcilroy
richiemcilroy merged commit fb84e75 into CapSoftware:main Oct 24, 2026
40 of 42 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants