diff options
| -rw-r--r-- | evil-helm.el | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/evil-helm.el b/evil-helm.el index aad9b81..1658f58 100644 --- a/evil-helm.el +++ b/evil-helm.el @@ -44,15 +44,15 @@ (defun evil-helm-setup () "Set up `evil' bindings for `helm'." - ;; TODO: We should not modify helm-map in Emacs state but somehow it does not - ;; work otherwise. - (define-key helm-map (kbd "M-[") 'helm-previous-source) - (define-key helm-map (kbd "M-]") 'helm-next-source) - (define-key helm-map (kbd "M-l") 'helm-execute-persistent-action) + (evil-define-key 'insert helm-map + (kbd "M-[") 'helm-previous-source + (kbd "M-]") 'helm-next-source + (kbd "M-l") 'helm-execute-persistent-action) (dolist (map (list helm-find-files-map helm-read-file-map)) - (define-key map (kbd "M-h") 'helm-find-files-up-one-level) - (define-key map (kbd "M-l") 'helm-execute-persistent-action) ; TODO: Inheritance does not seem to work for that binding. - (define-key map (kbd "C-l") nil)) ; So the header displays the above binding. + (evil-define-key 'insert map + (kbd "M-h") 'helm-find-files-up-one-level + (kbd "M-l") 'helm-execute-persistent-action) + (define-key map (kbd "C-l") nil)) ; So the Helm header displays the "M-l" binding. (evil-define-key 'normal helm-map (kbd "[") 'helm-previous-source |
