emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] master cace203: Unbreak echoing


From: Daniel Colascione
Subject: [Emacs-diffs] master cace203: Unbreak echoing
Date: Sat, 9 Jun 2018 21:14:26 -0400 (EDT)

branch: master
commit cace203da108da4d281a99953a6fc71a18cde029
Author: Daniel Colascione <address@hidden>
Commit: Daniel Colascione <address@hidden>

    Unbreak echoing
    
    * src/keyboard.c (read_key_sequence): Don't echo_truncate the first time.
---
 src/keyboard.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/src/keyboard.c b/src/keyboard.c
index bd9292c..c92684d 100644
--- a/src/keyboard.c
+++ b/src/keyboard.c
@@ -8964,6 +8964,9 @@ read_key_sequence (Lisp_Object *keybuf, int bufsize, 
Lisp_Object prompt,
      the first time we remember a mouse event.  */
   Lisp_Object used_mouse_menu_history = Qnil;
 
+  /* Distinguish first time through from replay with mock_input == 0.  */
+  bool is_replay = false;
+
   /* If the sequence is unbound in submaps[], then
      keybuf[fkey.start..fkey.end-1] is a prefix in Vfunction_key_map,
      and fkey.map is its binding.
@@ -9072,8 +9075,9 @@ read_key_sequence (Lisp_Object *keybuf, int bufsize, 
Lisp_Object prompt,
   /* These are no-ops the first time through, but if we restart, they
      revert the echo area and this_command_keys to their original state.  */
   this_command_key_count = keys_start;
-  if (INTERACTIVE)
+  if (INTERACTIVE && is_replay)
     echo_truncate (echo_start);
+  is_replay = true;
 
   /* If the best binding for the current key sequence is a keymap, or
      we may be looking at a function key's escape sequence, keep on



reply via email to

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