]> git.eshelyaron.com Git - emacs.git/commitdiff
* lisp/repeat.el (repeat-post-hook): Skip repeating in minibuffer (bug#47566).
authorJuri Linkov <juri@linkov.net>
Thu, 8 Apr 2021 18:43:35 +0000 (21:43 +0300)
committerJuri Linkov <juri@linkov.net>
Thu, 8 Apr 2021 18:54:43 +0000 (21:54 +0300)
(repeat-map)<defvar>: Add docstring.

lisp/repeat.el

index 1830bcc04970db413c3e45849dea1fb7fc9a0f0b..8cbfaa07487f6af59682e6f253f7a3b9bddb6411 100644 (file)
@@ -348,7 +348,11 @@ For example, you can set it to <return> like `isearch-exit'."
   :group 'convenience
   :version "28.1")
 
-;;;###autoload (defvar repeat-map nil)
+;;;###autoload
+(defvar repeat-map nil
+  "The value of the repeating map for the next command.
+A command called from the map can set it again to the same map when
+the map can't be set on the command symbol property `repeat-map'.")
 
 ;;;###autoload
 (define-minor-mode repeat-mode
@@ -388,8 +392,9 @@ When Repeat mode is enabled, and the command symbol has the property named
 
           ;; Exit when the last char is not among repeatable keys,
           ;; so e.g. `C-x u u' repeats undo, whereas `C-/ u' doesn't.
-          (when (or (lookup-key map (this-single-command-keys) nil)
-                    prefix-command-p)
+          (when (and (zerop (minibuffer-depth)) ; avoid remapping in prompts
+                     (or (lookup-key map (this-command-keys-vector))
+                         prefix-command-p))
 
             (when (and repeat-keep-prefix (not prefix-command-p))
               (setq prefix-arg current-prefix-arg))