emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] trunk r117190: * lisp/subr.el (sit-for): Remove universal-


From: Stefan Monnier
Subject: [Emacs-diffs] trunk r117190: * lisp/subr.el (sit-for): Remove universal-arg dependency.
Date: Thu, 29 May 2014 15:36:13 +0000
User-agent: Bazaar (2.6b2)

------------------------------------------------------------
revno: 117190
revision-id: address@hidden
parent: address@hidden
committer: Stefan Monnier <address@hidden>
branch nick: trunk
timestamp: Thu 2014-05-29 11:36:09 -0400
message:
  * lisp/subr.el (sit-for): Remove universal-arg dependency.
modified:
  lisp/subr.el                   subr.el-20091113204419-o5vbwnq5f7feedwu-151
=== modified file 'lisp/subr.el'
--- a/lisp/subr.el      2014-05-28 06:51:36 +0000
+++ b/lisp/subr.el      2014-05-29 15:36:09 +0000
@@ -2181,12 +2181,16 @@
     (let ((read (read-event nil t seconds)))
       (or (null read)
          (progn
-           ;; If last command was a prefix arg, e.g. C-u, push this event onto
-           ;; unread-command-events as (t . EVENT) so it will be added to
-           ;; this-command-keys by read-key-sequence.
-           (if (eq overriding-terminal-local-map universal-argument-map)
-               (setq read (cons t read)))
-           (push read unread-command-events)
+            ;; 
https://lists.gnu.org/archive/html/emacs-devel/2006-10/msg00394.html
+            ;; We want `read' appear in the next command's this-command-event
+            ;; but not in the current one.
+            ;; By pushing (cons t read), we indicate that `read' has not
+            ;; yet been recorded in this-command-keys, so it will be recorded
+            ;; next time it's read.
+            ;; And indeed the `seconds' argument to read-event correctly
+            ;; prevented recording this event in the current command's
+            ;; this-command-keys.
+           (push (cons t read) unread-command-events)
            nil))))))
 
 ;; Behind display-popup-menus-p test.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]