From: Po Lu Date: Thu, 23 Dec 2021 13:35:46 +0000 (+0800) Subject: Make precision scrolling also work on various bars X-Git-Tag: emacs-29.0.90~3486 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=f9d518bc2f333e03d5e7c4e935b08fbe19f33c5b;p=emacs.git Make precision scrolling also work on various bars * lisp/pixel-scroll.el (pixel-scroll-precision-mode-map): Define keys for various kinds of bars. --- diff --git a/lisp/pixel-scroll.el b/lisp/pixel-scroll.el index 975c5133f11..d3b45000239 100644 --- a/lisp/pixel-scroll.el +++ b/lisp/pixel-scroll.el @@ -99,6 +99,15 @@ is always with pixel resolution.") (define-key map [wheel-down] #'pixel-scroll-precision) (define-key map [wheel-up] #'pixel-scroll-precision) (define-key map [touch-end] #'pixel-scroll-start-momentum) + (define-key map [mode-line wheel-down] #'pixel-scroll-precision) + (define-key map [mode-line wheel-up] #'pixel-scroll-precision) + (define-key map [mode-line touch-end] #'pixel-scroll-start-momentum) + (define-key map [header-line wheel-down] #'pixel-scroll-precision) + (define-key map [header-line wheel-up] #'pixel-scroll-precision) + (define-key map [header-line touch-end] #'pixel-scroll-start-momentum) + (define-key map [vertical-scroll-bar wheel-down] #'pixel-scroll-precision) + (define-key map [vertical-scroll-bar wheel-up] #'pixel-scroll-precision) + (define-key map [vertical-scroll-bar touch-end] #'pixel-scroll-start-momentum) map) "The key map used by `pixel-scroll-precision-mode'.")