Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Focus new item if pane was focused when removing previous active item
Antonio Scandurra37d3ed5f5f63
diff --git a/crates/workspace/src/pane.rs b/crates/workspace/src/pane.rsindex 0523f082ea5..30e782c7501 100644--- a/crates/workspace/src/pane.rs+++ b/crates/workspace/src/pane.rs@@ -903,7 +903,8 @@ impl Pane {// to activating the item to the left.unwrap_or_else(|| item_index.min(self.items.len()).saturating_sub(1));- self.activate_item(index_to_activate, activate_pane, activate_pane, cx);+ let should_activate = activate_pane || self.has_focus;+ self.activate_item(index_to_activate, should_activate, should_activate, cx);}let item = self.items.remove(item_index);