diff options
author | Kyle Meyer <kyle@kyleam.com> | 2014-11-02 01:32:43 -0400 |
---|---|---|
committer | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2014-11-03 21:07:20 +0100 |
commit | 4508b8c2a7f2bf3928967adb1cab20aff466e5bd (patch) | |
tree | dc8b92981a513ba5600a1482c0be39eaa2d392f7 | |
parent | 20dcd061a51a8121ff958fc0edb5b7c52ba4e0e0 (diff) | |
download | org-mode-4508b8c2a7f2bf3928967adb1cab20aff466e5bd.tar.gz |
org-goto: Update for isearch changes
* lisp/org.el (org-goto): Update for isearch changes that removed
isearch-other-control-char.
isearch-other-control-char has been removed from isearch.el [1]. The
default interface for org-goto uses isearch-other-control-char to pass
certain key presses from org-goto-local-auto-isearch-map to
org-goto-map. Specifically, 'C-i' calls org-cycle and 'C-m' calls
org-goto-ret.
With the current isearch, the keys that should be passed to org-goto-map
can be set to nil. In addition to 'C-i' and 'C-m', RET must also be set
to nil because isearch-mode-map sets both 'C-m' and RET.
[1] bzr revision 114586, git commit aa04ac2c6,
http://debbugs.gnu.org/cgi/bugreport.cgi?bug=15200
<http://thread.gmane.org/gmane.emacs.orgmode/92317>
-rw-r--r-- | lisp/org.el | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/lisp/org.el b/lisp/org.el index ff086c6..6343746 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -7399,8 +7399,14 @@ or nil." (defvar org-goto-local-auto-isearch-map (make-sparse-keymap)) (set-keymap-parent org-goto-local-auto-isearch-map isearch-mode-map) -(define-key org-goto-local-auto-isearch-map "\C-i" 'isearch-other-control-char) -(define-key org-goto-local-auto-isearch-map "\C-m" 'isearch-other-control-char) +;; `isearch-other-control-char' was removed in Emacs 24.4. +(if (fboundp 'isearch-other-control-char) + (progn + (define-key org-goto-local-auto-isearch-map "\C-i" 'isearch-other-control-char) + (define-key org-goto-local-auto-isearch-map "\C-m" 'isearch-other-control-char)) + (define-key org-goto-local-auto-isearch-map "\C-i" nil) + (define-key org-goto-local-auto-isearch-map "\C-m" nil) + (define-key org-goto-local-auto-isearch-map [return] nil)) (defun org-goto-local-search-headings (string bound noerror) "Search and make sure that any matches are in headlines." |