From 2178e8589a6f650eba114153be01d14f9ed08b60 Mon Sep 17 00:00:00 2001 From: Juri Linkov Date: Mon, 16 Dec 2013 22:32:15 +0200 Subject: [PATCH] * lisp/isearch.el (isearch-mode-map): Remove [escape] key bindinds. (isearch-pre-command-hook): Check `this-command' for symbolp. Fixes: debbugs:16035 --- lisp/ChangeLog | 6 ++++++ lisp/isearch.el | 5 ++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 6b0b8fc67d8..0cf8ed3da1e 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2013-12-16 Juri Linkov + + * isearch.el (isearch-mode-map): Remove [escape] key bindinds. + (Bug#16035) + (isearch-pre-command-hook): Check `this-command' for symbolp. + 2013-12-16 Stefan Monnier * emacs-lisp/gv.el (gv-ref): Mention lexbind restriction (bug#16153). diff --git a/lisp/isearch.el b/lisp/isearch.el index b411396cc70..02b121621a6 100644 --- a/lisp/isearch.el +++ b/lisp/isearch.el @@ -435,8 +435,7 @@ This is like `describe-bindings', but displays only Isearch keys." ;; would be simpler to disable the global keymap, and/or have a ;; default local key binding for any key not otherwise bound. (let ((meta-map (make-sparse-keymap))) - (define-key map (char-to-string meta-prefix-char) meta-map) - (define-key map [escape] meta-map)) + (define-key map (char-to-string meta-prefix-char) meta-map)) ;; Several non-printing chars change the searching behavior. (define-key map "\C-s" 'isearch-repeat-forward) @@ -453,7 +452,6 @@ This is like `describe-bindings', but displays only Isearch keys." (or (= ?\e meta-prefix-char) (error "Inconsistency in isearch.el")) (define-key map "\e\e\e" 'isearch-cancel) - (define-key map [escape escape escape] 'isearch-cancel) (define-key map "\C-q" 'isearch-quote-char) @@ -2251,6 +2249,7 @@ before the command is executed globally with terminated Isearch." (memq this-command '(universal-argument digit-argument negative-argument))) (and isearch-allow-scroll + (symbolp this-command) (or (eq (get this-command 'isearch-scroll) t) (eq (get this-command 'scroll-command) t)))) (when isearch-allow-scroll -- 2.11.4.GIT