feature/evil: refactor evil-force-normal-state advice into +evil-esc-hook

This commit is contained in:
Henrik Lissner 2017-05-07 19:12:48 +02:00
parent 69f6eab913
commit cce294fcf6
7 changed files with 29 additions and 16 deletions

View file

@ -363,10 +363,10 @@
(IS-LINUX "xdg-open \"%s\"")))))
;; Remove highlights on ESC
(defun +org*remove-occur-highlights (&rest args)
(defun +org|remove-occur-highlights (&rest args)
(when (eq major-mode 'org-mode)
(org-remove-occur-highlights)))
(advice-add #'evil-force-normal-state :before #'+org*remove-occur-highlights)
(add-hook '+evil-esc-hook #'+org|remove-occur-highlights)
(after! org-bullets
(define-minor-mode org-bullets-mode