From b21c25826dc84dc68eea21033a9775d93412b48c Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Fri, 3 Nov 2023 15:51:33 +0100 Subject: [PATCH] Make tab bar visible --- crates/editor2/src/items.rs | 5 ++--- crates/workspace2/src/pane.rs | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/crates/editor2/src/items.rs b/crates/editor2/src/items.rs index c439adcc44..84263d4ed7 100644 --- a/crates/editor2/src/items.rs +++ b/crates/editor2/src/items.rs @@ -578,12 +578,12 @@ impl Item for Editor { fn tab_content(&self, detail: Option, cx: &AppContext) -> AnyElement { let theme = cx.theme(); + AnyElement::new( div() .flex() .flex_row() .items_center() - .bg(gpui::white()) .text_color(gpui::white()) .child(self.title(cx).to_string()) .children(detail.and_then(|detail| { @@ -625,8 +625,7 @@ impl Item for Editor { fn deactivated(&mut self, cx: &mut ViewContext) { let selection = self.selections.newest_anchor(); - todo!() - // self.push_to_nav_history(selection.head(), None, cx); + self.push_to_nav_history(selection.head(), None, cx); } fn workspace_deactivated(&mut self, cx: &mut ViewContext) { diff --git a/crates/workspace2/src/pane.rs b/crates/workspace2/src/pane.rs index acc41deba8..c56defed26 100644 --- a/crates/workspace2/src/pane.rs +++ b/crates/workspace2/src/pane.rs @@ -1457,7 +1457,7 @@ impl Pane { ), ) .child( - div().w_0().flex_1().h_full().child( + div().flex_1().h_full().child( div().id("tabs").flex().overflow_x_scroll().children( self.items .iter()