From 3f72fac8655baf2940a6be61d59e2a6d7e80ae73 Mon Sep 17 00:00:00 2001 From: Phillip Rulon Date: Sun, 10 Oct 1999 01:22:34 +0000 Subject: [PATCH] (map-y-or-n-p): If we read -1, for end of keyboard macro, try again. --- lisp/map-ynp.el | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lisp/map-ynp.el b/lisp/map-ynp.el index 3180be4d68b..e0b150be721 100644 --- a/lisp/map-ynp.el +++ b/lisp/map-ynp.el @@ -149,7 +149,11 @@ Returns the number of actions taken." (key-description (vector help-char))) (if minibuffer-auto-raise (raise-frame (window-frame (minibuffer-window)))) - (setq char (read-event)) + (while (progn + (setq char (read-event)) + ;; If we get -1, from end of keyboard + ;; macro, try again. + (not (equal char -1)))) ;; Show the answer to the question. (message "%s(y, n, !, ., q, %sor %s) %s" prompt user-keys -- 2.39.5