aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJuri Linkov2021-08-18 20:52:32 +0300
committerJuri Linkov2021-08-18 20:52:32 +0300
commitad9c57f54ae3eea9e5b2fe9264e9edb8b2ed1857 (patch)
tree757b9cc38da6901fe3ce86e3151784c65c14618d /src
parent56d567acb6eae72352e39acf4f206f7cb3195900 (diff)
downloademacs-ad9c57f54ae3eea9e5b2fe9264e9edb8b2ed1857.tar.gz
emacs-ad9c57f54ae3eea9e5b2fe9264e9edb8b2ed1857.zip
Mouse wheel scrolling on the tab bar
* lisp/tab-bar.el (tab-bar-map): Bind mouse-4/wheel-up/wheel-left to tab-previous and mouse-5/wheel-down/wheel-right to tab-next. Bind S-mouse-4/wheel-up/wheel-left to tab-bar-move-tab-backward and S-mouse-5/wheel-down/wheel-right to tab-bar-move-tab. (tab-bar-move-tab-backward): New command. (tab-bar-move-repeat-map): Use tab-bar-move-tab-backward instead of lambda. * src/xterm.c (handle_one_xevent): Remove restriction to allow clicking mouse-4 and mouse-5.
Diffstat (limited to 'src')
-rw-r--r--src/xterm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/xterm.c b/src/xterm.c
index 80fa747b97d..57229d3d616 100644
--- a/src/xterm.c
+++ b/src/xterm.c
@@ -9215,7 +9215,7 @@ handle_one_xevent (struct x_display_info *dpyinfo,
9215 window = window_from_coordinates (f, x, y, 0, true, true); 9215 window = window_from_coordinates (f, x, y, 0, true, true);
9216 tab_bar_p = EQ (window, f->tab_bar_window); 9216 tab_bar_p = EQ (window, f->tab_bar_window);
9217 9217
9218 if (tab_bar_p && event->xbutton.button < 4) 9218 if (tab_bar_p)
9219 tab_bar_key = handle_tab_bar_click 9219 tab_bar_key = handle_tab_bar_click
9220 (f, x, y, event->xbutton.type == ButtonPress, 9220 (f, x, y, event->xbutton.type == ButtonPress,
9221 x_x_to_emacs_modifiers (dpyinfo, event->xbutton.state)); 9221 x_x_to_emacs_modifiers (dpyinfo, event->xbutton.state));