diff options
| author | Eli Zaretskii | 2000-08-07 07:50:13 +0000 |
|---|---|---|
| committer | Eli Zaretskii | 2000-08-07 07:50:13 +0000 |
| commit | f244674ca597cfbabdceaa1fd20cba629d3c17bb (patch) | |
| tree | 0cea02a38ebbfe9f6ad9d7730a5195fbf7c671f2 | |
| parent | 84968b32fd9d5c486ed7aa17f7b9bea9a5732e44 (diff) | |
| download | emacs-f244674ca597cfbabdceaa1fd20cba629d3c17bb.tar.gz emacs-f244674ca597cfbabdceaa1fd20cba629d3c17bb.zip | |
(zone): Discard any pending input before running
the randomly-chosen pgm.
| -rw-r--r-- | lisp/play/zone.el | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lisp/play/zone.el b/lisp/play/zone.el index 6f2340d0485..f0c5ded1b1d 100644 --- a/lisp/play/zone.el +++ b/lisp/play/zone.el | |||
| @@ -107,6 +107,12 @@ | |||
| 107 | (progn | 107 | (progn |
| 108 | (message "Zoning... (%s)" pgm) | 108 | (message "Zoning... (%s)" pgm) |
| 109 | (garbage-collect) | 109 | (garbage-collect) |
| 110 | ;; If some input is pending, zone says "sorry", which | ||
| 111 | ;; isn't nice; this might happen e.g. when they invoke the | ||
| 112 | ;; game by clicking the menu bar. So discard any pending | ||
| 113 | ;; input before zoning out. | ||
| 114 | (if (input-pending-p) | ||
| 115 | (discard-input)) | ||
| 110 | (funcall pgm) | 116 | (funcall pgm) |
| 111 | (message "Zoning...sorry")) | 117 | (message "Zoning...sorry")) |
| 112 | (error | 118 | (error |