terminal
terminal copied to clipboard
Add `tab.closeButton: activeOnly`
TabView is a part of WinUI, and that code is available over at https://github.com/microsoft/microsoft-ui-xaml/
I want to know if it's even possible on the current version of
TabViewto actualize what that enum would represent?
Hm. https://github.com/microsoft/terminal/blob/a9c3b7724c05a0da059c4a0433ea446f8e19cbff/src/cascadia/TerminalApp/TerminalPage.cpp#L2740-L2772
- We could take that, turn that into a method.
- Call that method every time the active tab changes...
- ... or the set of tabs changes.
- Get rid of all the calls to
_updateTabCloseButton, cause that only updates a single tab. - Add logic in that method
- Inside the loop, if the mode is
ActiveOnly, and the tab is active, thenIsClosable(true). elsefalse - Outside the loop, set
CloseButtonOverlayModetoAuto, probably a sensible default.
- Inside the loop, if the mode is
That sounds like it would work on paper. Wanna file a PR? 😄
Originally posted by @zadjii-msft in https://github.com/microsoft/terminal/issues/3335#issuecomment-1203867172
I have a question,for:
Call that method every time the active tab change ... or the set of tabs changes.
what would be the best way to implement this(as in check which tab(s) are active)?