Fix dragging by left or right status with retro tab bar

Another good example of why `_ =>` in a match is probably a bad idea.

refs: https://github.com/wez/wezterm/issues/2758
This commit is contained in:
Wez Furlong committed 2022-11-19 08:26:33 -07:00
1 parent d96b05c06c
commit fde535faf1
2 files changed
+4 -2

No files matched your search

+2
View File
@@ -116,6 +116,8 @@ As features stabilize some brief notes about them will accumulate here.
`SUPER+SHIFT+Page(Up|Down)` instead of the documented
`CTRL+SHIFT+Page(Up|Down)`
[#2705](https://github.com/wez/wezterm/issues/2705)
* Dragging by retro tab bar left or right status area would jump around erratically.
[#2758](https://github.com/wez/wezterm/issues/2758)
#### Changed
+2 -2
View File
@@ -435,10 +435,10 @@ impl super::TermWindow {
TabBarItem::None | TabBarItem::LeftStatus | TabBarItem::RightStatus => {}
},
WMEK::Move => match item {
TabBarItem::None => {
TabBarItem::None | TabBarItem::LeftStatus | TabBarItem::RightStatus => {
context.set_window_drag_position(event.screen_coords);
}
_ => {}
TabBarItem::Tab { .. } | TabBarItem::NewTabButton { .. } => {}
},
WMEK::VertWheel(n) => {
self.activate_tab_relative(if n < 1 { 1 } else { -1 }, true)