Add each panel to the workspace as soon as it's ready (#43414)

We'll now add panels to the workspace as soon as they're ready rather
than waiting for all the rest to complete. We should strive to make all
panels fast, but given that their load tasks are fallible and do IO,
this approach seems more resilient.

Additionally, we'll now start loading the agent panel at the same time
as the rest.

Release Notes:

- workspace: Add panels as soon as they are ready
This commit is contained in:
Agus Zubiaga
2025-11-24 14:41:40 -03:00
committed by GitHub
parent 4a36f67f94
commit a7fff59136
4 changed files with 123 additions and 105 deletions
+1 -1
View File
@@ -529,7 +529,7 @@ async fn test_basic_following(
});
// Client B activates a panel, and the previously-opened screen-sharing item gets activated.
let panel = cx_b.new(|cx| TestPanel::new(DockPosition::Left, cx));
let panel = cx_b.new(|cx| TestPanel::new(DockPosition::Left, 100, cx));
workspace_b.update_in(cx_b, |workspace, window, cx| {
workspace.add_panel(panel, window, cx);
workspace.toggle_panel_focus::<TestPanel>(window, cx);