aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMiles Bader2002-03-02 08:21:33 +0000
committerMiles Bader2002-03-02 08:21:33 +0000
commitadf953ac72081b6238b88a1bf99efa2823b01eff (patch)
treeebfba885a9c9ea22ff499cef07266d442d63c492
parent3bdb7f808776ee824765fe596e83935f375880b3 (diff)
downloademacs-adf953ac72081b6238b88a1bf99efa2823b01eff.tar.gz
emacs-adf953ac72081b6238b88a1bf99efa2823b01eff.zip
(mwheel-scroll): Remove `double' and `triple' from the
event-modifiers before looking up in `mouse-wheel-scroll-amount'. If there's no applicable modifiers entry in the alist in `mouse-wheel-scroll-amount', fall back to the default, not to nil (which causes full screen scrolls).
-rw-r--r--lisp/ChangeLog8
-rw-r--r--lisp/mwheel.el10
2 files changed, 14 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index f971abde39d..76e84ecb888 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,11 @@
12002-03-02 Miles Bader <miles@gnu.org>
2
3 * mwheel.el (mwheel-scroll): Remove `double' and `triple' from the
4 event-modifiers before looking up in `mouse-wheel-scroll-amount'.
5 If there's no applicable modifiers entry in the alist in
6 `mouse-wheel-scroll-amount', fall back to the default, not to
7 nil (which causes full screen scrolls).
8
12002-03-01 Andreas Schwab <schwab@suse.de> 92002-03-01 Andreas Schwab <schwab@suse.de>
2 10
3 * textmodes/texnfo-upd.el (texinfo-start-menu-description): Remove 11 * textmodes/texnfo-upd.el (texinfo-start-menu-description): Remove
diff --git a/lisp/mwheel.el b/lisp/mwheel.el
index 4080e7451ed..27a487d0ef6 100644
--- a/lisp/mwheel.el
+++ b/lisp/mwheel.el
@@ -122,10 +122,12 @@ This should only be bound to mouse buttons 4 and 5."
122 (prog1 122 (prog1
123 (selected-window) 123 (selected-window)
124 (select-window (mwheel-event-window event))))) 124 (select-window (mwheel-event-window event)))))
125 (mods (delete 'click (event-modifiers event))) 125 (mods
126 (amt (if mods 126 (delq 'click (delq 'double (delq 'triple (event-modifiers event)))))
127 (cdr (assoc mods (cdr mouse-wheel-scroll-amount))) 127 (amt
128 (car mouse-wheel-scroll-amount)))) 128 (or (and mods
129 (cdr (assoc mods (cdr mouse-wheel-scroll-amount))))
130 (car mouse-wheel-scroll-amount))))
129 (if (floatp amt) (setq amt (1+ (truncate (* amt (window-height)))))) 131 (if (floatp amt) (setq amt (1+ (truncate (* amt (window-height))))))
130 (when (and mouse-wheel-progessive-speed (numberp amt)) 132 (when (and mouse-wheel-progessive-speed (numberp amt))
131 ;; When the double-mouse-N comes in, a mouse-N has been executed already, 133 ;; When the double-mouse-N comes in, a mouse-N has been executed already,