diff options
| author | Eivind Fonn <evfonn@gmail.com> | 2020-01-25 16:02:05 +0100 |
|---|---|---|
| committer | Eivind Fonn <evfonn@gmail.com> | 2020-01-26 10:06:05 +0100 |
| commit | 3a4ea09bddb3ed90496a19eda690f1e73bf09bde (patch) | |
| tree | 21504dd44eb375d6915ce4641b8e143150145f1a | |
| parent | 30b77c9ab3e47f3e6e206f43de2edba405b062bf (diff) | |
Ex search highlights: use selected window as fallback
In some cases search is triggered not from the minibuffer, in which
case minibuffer-selected-window will not accurately capture the window
in which search highlights should be created.
| -rw-r--r-- | evil-search.el | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/evil-search.el b/evil-search.el index 570d627..a08f63e 100644 --- a/evil-search.el +++ b/evil-search.el @@ -778,7 +778,7 @@ This function does nothing if `evil-ex-search-interactive' or (with-current-buffer (or evil-ex-current-buffer (current-buffer)) (unless (evil-ex-hl-active-p 'evil-ex-search) (evil-ex-make-hl 'evil-ex-search - :win (minibuffer-selected-window))) + :win (or (minibuffer-selected-window) (selected-window)))) (if pattern (evil-ex-hl-change 'evil-ex-search pattern))))) |
