emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[elpa] master 22ebc3a 34/68: ace-window.el (aw--doit): use map with most


From: Oleh Krehel
Subject: [elpa] master 22ebc3a 34/68: ace-window.el (aw--doit): use map with most priority
Date: Sat, 21 Mar 2015 19:06:59 +0000

branch: master
commit 22ebc3a34f247342b94196c6d0ae5c9bb7fe1bb4
Author: Oleh Krehel <address@hidden>
Commit: Oleh Krehel <address@hidden>

    ace-window.el (aw--doit): use map with most priority
    
    * ace-window.el (aw--doit): Use `set-transient-map' instead of `(setq
      overriding-local-map)`, as it has more priority and `helm' is using
      it. This will avoid the current conflict with helm.
    
    Re #15.
---
 ace-window.el |   14 ++++++++------
 1 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/ace-window.el b/ace-window.el
index 864bb1b..2e6cb57 100644
--- a/ace-window.el
+++ b/ace-window.el
@@ -218,12 +218,14 @@ Set mode line to MODE-LINE during the selection process."
          (setq ace-jump-mode mode-line)
          (force-mode-line-update)
          ;; override the local key map
-         (setq overriding-local-map
-               (let ((map (make-keymap)))
-                 (dolist (key-code aw-keys)
-                   (define-key map (make-string 1 key-code) 'aw--callback))
-                 (define-key map [t] 'ace-jump-done)
-                 map))
+         (let ((map (make-keymap)))
+           (dolist (key-code aw-keys)
+             (define-key map (make-string 1 key-code) 'aw--callback))
+           (define-key map [t] 'ace-jump-done)
+           (if (fboundp 'set-transient-map)
+               (set-transient-map map)
+             (set-temporary-overlay-map map)))
+
          (add-hook 'mouse-leave-buffer-hook 'ace-jump-done)
          (add-hook 'kbd-macro-termination-hook 'ace-jump-done))))))
 



reply via email to

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