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

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

[elpa] master 1c09e99 156/348: ivy.el (ivy-call): Use select-window, no


From: Oleh Krehel
Subject: [elpa] master 1c09e99 156/348: ivy.el (ivy-call): Use select-window, not with-ivy-window
Date: Sat, 8 Apr 2017 11:03:46 -0400 (EDT)

branch: master
commit 1c09e99153b36626fcb3d272973e7ef3cb5ee679
Author: Oleh Krehel <address@hidden>
Commit: Oleh Krehel <address@hidden>

    ivy.el (ivy-call): Use select-window, not with-ivy-window
    
    Since `with-ivy-window' relies on `with-selected-window', which restores
    the window state. This is bad if the purpose of the action was to change
    the selected window.
    
    So now we use only the first part of `with-ivy-window', which
    is (select-window (ivy--get-window ivy-last)).
    
    Fixes #639
---
 ivy.el | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/ivy.el b/ivy.el
index 64d3429..a48d63a 100644
--- a/ivy.el
+++ b/ivy.el
@@ -955,7 +955,8 @@ Example use:
                      ivy-text)
                     (t
                      ivy--current))))
-          (prog1 (with-ivy-window (funcall action x))
+          (select-window (ivy--get-window ivy-last))
+          (prog1 (funcall action x)
             (unless (or (eq ivy-exit 'done)
                         (equal (selected-window)
                                (active-minibuffer-window))



reply via email to

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