changeset 69327:f309eed94981

* help.el (describe-key-briefly): If KEY is a down event, read and discard the up event.
author Chong Yidong <cyd@stupidchicken.com>
date Tue, 07 Mar 2006 15:53:41 +0000
parents b7c903d07d4f
children 7383e30e90bb
files lisp/ChangeLog lisp/help.el
diffstat 2 files changed, 11 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Tue Mar 07 10:43:19 2006 +0000
+++ b/lisp/ChangeLog	Tue Mar 07 15:53:41 2006 +0000
@@ -1,3 +1,8 @@
+2006-03-07  Chong Yidong  <cyd@stupidchicken.com>
+
+	* help.el (describe-key-briefly): If KEY is a down event, read and
+	discard the up event.
+
 2006-03-07  Nick Roberts  <nickrob@snap.net.nz>
 
 	* progmodes/gud.el (gud-speedbar-buttons): Allow pointers to
--- a/lisp/help.el	Tue Mar 07 10:43:19 2006 +0000
+++ b/lisp/help.el	Tue Mar 07 15:53:41 2006 +0000
@@ -577,6 +577,12 @@
 	     (setq saved-yank-menu (copy-sequence yank-menu))
 	     (menu-bar-update-yank-menu "(any string)" nil))
 	   (setq key (read-key-sequence "Describe key (or click or menu item): "))
+	   ;; If KEY is a down-event, read and discard the
+	   ;; corresponding up-event.
+	   (if (and (vectorp key)
+		    (eventp (elt key 0))
+		    (memq 'down (event-modifiers (elt key 0))))
+	       (read-event))
 	   (list
 	    key
 	    (if current-prefix-arg (prefix-numeric-value current-prefix-arg))