diff options
| author | Richard M. Stallman | 1993-03-09 21:17:46 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1993-03-09 21:17:46 +0000 |
| commit | 81eb8fcd8dc8ac7692ec125014f4ec2fe14d5f25 (patch) | |
| tree | be1e4c50826d533b3334ca98690f24a1dfbf15c6 | |
| parent | 0a2eb25e0527bb91575a3bdc4b978fad1f2c46c5 (diff) | |
| download | emacs-81eb8fcd8dc8ac7692ec125014f4ec2fe14d5f25.tar.gz emacs-81eb8fcd8dc8ac7692ec125014f4ec2fe14d5f25.zip | |
(map-y-or-n-p): Handle `quit' as answer.
| -rw-r--r-- | lisp/map-ynp.el | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lisp/map-ynp.el b/lisp/map-ynp.el index e79e47fa664..c3cce3abc07 100644 --- a/lisp/map-ynp.el +++ b/lisp/map-ynp.el | |||
| @@ -111,6 +111,7 @@ Returns the number of actions taken." | |||
| 111 | (setq prompt (funcall prompter elt)) | 111 | (setq prompt (funcall prompter elt)) |
| 112 | (if (stringp prompt) | 112 | (if (stringp prompt) |
| 113 | (progn | 113 | (progn |
| 114 | (setq quit-flag nil) | ||
| 114 | ;; Prompt the user about this object. | 115 | ;; Prompt the user about this object. |
| 115 | (let ((cursor-in-echo-area t)) | 116 | (let ((cursor-in-echo-area t)) |
| 116 | (message "%s(y, n, !, ., q, %sor %s) " | 117 | (message "%s(y, n, !, ., q, %sor %s) " |
| @@ -132,6 +133,11 @@ Returns the number of actions taken." | |||
| 132 | (funcall actor elt) | 133 | (funcall actor elt) |
| 133 | (setq actions (1+ actions) | 134 | (setq actions (1+ actions) |
| 134 | next (function (lambda () nil)))) | 135 | next (function (lambda () nil)))) |
| 136 | ((eq def 'quit) | ||
| 137 | (setq quit-flag t) | ||
| 138 | (setq next (` (lambda () | ||
| 139 | (setq next '(, next)) | ||
| 140 | '(, elt))))) | ||
| 135 | ((eq def 'automatic) | 141 | ((eq def 'automatic) |
| 136 | ;; Act on this and all following objects. | 142 | ;; Act on this and all following objects. |
| 137 | (if (eval (funcall prompter elt)) | 143 | (if (eval (funcall prompter elt)) |