Fix tab bar button's focus handling lagging behind
This fixes https://github.com/zed-industries/community/issues/2442 for me. Previously, the tab bar buttons would stay when the chat panel was opened (and received focus) until something else was drawn (or caused a render?) With this change, the tab bar buttons are only shown if the pane was focus. I'm not sure about the side-effects of this, but the toolbar still seems to work fine.
This commit is contained in:
parent
e01850642f
commit
027f425804
1 changed files with 1 additions and 1 deletions
|
@ -1470,7 +1470,7 @@ impl Pane {
|
|||
),
|
||||
)
|
||||
})
|
||||
.when(self.was_focused || self.has_focus(cx), |tab_bar| {
|
||||
.when(self.has_focus(cx), |tab_bar| {
|
||||
tab_bar.end_child({
|
||||
let render_tab_buttons = self.render_tab_bar_buttons.clone();
|
||||
render_tab_buttons(self, cx)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue