From 733042cb7fca4802ddf158ce68303bcdcab12240 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Thu, 25 May 2017 12:12:38 +0200 Subject: [PATCH] Refactor anzu--reset-status hooks --- modules/ui/doom-modeline/config.el | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/modules/ui/doom-modeline/config.el b/modules/ui/doom-modeline/config.el index 4301c30e6..66d689014 100644 --- a/modules/ui/doom-modeline/config.el +++ b/modules/ui/doom-modeline/config.el @@ -48,11 +48,9 @@ anzu--cached-count anzu--cached-positions anzu--last-command anzu--last-isearch-string anzu--overflow-p)) - (defun +doom-modeline|reset-anzu () - (anzu--reset-status)) ;; Ensure anzu state is cleared when searches & iedit are done - (add-hook! :append '(kill-buffer isearch-mode-end +evil-esc-hook) - #'+doom-modeline|reset-anzu) + (add-hook! :append '(isearch-mode-end-hook +evil-esc-hook) + #'anzu--reset-status) (after! iedit (add-hook 'iedit-mode-end-hook #'+doom-modeline|reset-anzu)))