tab_switcher: Add tab close buttons (#9968)

Support for closing tabs from Tab Switcher:

- Close button color matches the indicator color to preserve the
information that the buffer is dirty (as in SublimeText).
- `ctrl-backspace` closes the currently selected item.


https://github.com/zed-industries/zed/assets/2101250/8ea33911-2f62-4199-826d-c17556db8e9a

Release Notes:

- N/A
This commit is contained in:
Andrew Lygin
2024-04-03 17:28:51 +02:00
committed by GitHub
parent 8eeecdafec
commit 57a1b9b2cd
6 changed files with 156 additions and 13 deletions
+4 -1
View File
@@ -598,7 +598,10 @@
},
{
"context": "TabSwitcher",
"bindings": { "ctrl-shift-tab": "menu::SelectPrev" }
"bindings": {
"ctrl-shift-tab": "menu::SelectPrev",
"ctrl-backspace": "tab_switcher::CloseSelectedItem"
}
},
{
"context": "Terminal",