From: Glenn Morris Date: Fri, 15 Jul 2011 22:53:39 +0000 (-0400) Subject: * lisp/subr.el (read-char-choice): Allow quitting. (Bug#9001) X-Git-Tag: emacs-pretest-24.0.90~104^2~236 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=6ccf7859d6814efcfe7745e1fdd4a2b5964a8952;p=emacs.git * lisp/subr.el (read-char-choice): Allow quitting. (Bug#9001) --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 6bfdb61330b..1a2c8daed5b 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2011-07-15 Glenn Morris + + * subr.el (read-char-choice): Allow quitting. (Bug#9001) + 2011-07-09 Lawrence Mitchell * net/gnutls.el (gnutls-min-prime-bits): New variable. diff --git a/lisp/subr.el b/lisp/subr.el index 94b28c007d1..d462283b7bd 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -2161,7 +2161,9 @@ keyboard-quit events while waiting for a valid input." ;; read-event returns -1 if we are in a kbd macro and ;; there are no more events in the macro. Attempt to ;; get an event interactively. - (setq executing-kbd-macro nil))))) + (setq executing-kbd-macro nil)) + ((and (not inhibit-keyboard-quit) (eq char ?\C-g)) + (keyboard-quit))))) ;; Display the question with the answer. But without cursor-in-echo-area. (message "%s%s" prompt (char-to-string char)) char))