comparison lisp/subr.el @ 47305:3feceef12d3a

(read-quoted-char): Apply listify-key-sequence to vector returned by this-single-command-raw-keys before appending it to unread-command-event.
author Kim F. Storm <storm@cua.dk>
date Sat, 07 Sep 2002 22:50:44 +0000
parents 6e9df2174ee2
children 9e3ee43b5262
comparison
equal deleted inserted replaced
47304:2ae3c0d6525a 47305:3feceef12d3a
1090 any other non-digit terminates the character code and is then used as input.")) 1090 any other non-digit terminates the character code and is then used as input."))
1091 (setq char (read-key (and prompt (format "%s-" prompt)))) 1091 (setq char (read-key (and prompt (format "%s-" prompt))))
1092 (if inhibit-quit (setq quit-flag nil))) 1092 (if inhibit-quit (setq quit-flag nil)))
1093 (cond ((null char)) 1093 (cond ((null char))
1094 ((not (integerp char)) 1094 ((not (integerp char))
1095 (setq unread-command-events (this-single-command-raw-keys) 1095 (setq unread-command-events (listify-key-sequence (this-single-command-raw-keys))
1096 done t)) 1096 done t))
1097 ((/= (logand char ?\M-\^@) 0) 1097 ((/= (logand char ?\M-\^@) 0)
1098 ;; Turn a meta-character into a character with the 0200 bit set. 1098 ;; Turn a meta-character into a character with the 0200 bit set.
1099 (setq code (logior (logand char (lognot ?\M-\^@)) 128) 1099 (setq code (logior (logand char (lognot ?\M-\^@)) 128)
1100 done t)) 1100 done t))
1107 (+ 10 (- (downcase char) ?a)))) 1107 (+ 10 (- (downcase char) ?a))))
1108 (and prompt (setq prompt (message "%s %c" prompt char)))) 1108 (and prompt (setq prompt (message "%s %c" prompt char))))
1109 ((and (not first) (eq char ?\C-m)) 1109 ((and (not first) (eq char ?\C-m))
1110 (setq done t)) 1110 (setq done t))
1111 ((not first) 1111 ((not first)
1112 (setq unread-command-events (this-single-command-raw-keys) 1112 (setq unread-command-events (listify-key-sequence (this-single-command-raw-keys))
1113 done t)) 1113 done t))
1114 (t (setq code char 1114 (t (setq code char
1115 done t))) 1115 done t)))
1116 (setq first nil)) 1116 (setq first nil))
1117 code)) 1117 code))