[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master 916e281 367/399: ivy.el (ivy-read): Fix bad refactor
From: |
Oleh Krehel |
Subject: |
[elpa] master 916e281 367/399: ivy.el (ivy-read): Fix bad refactor |
Date: |
Sat, 20 Jul 2019 14:58:00 -0400 (EDT) |
branch: master
commit 916e2816a27a371b56364aa64733415ba186847c
Author: Oleh Krehel <address@hidden>
Commit: Oleh Krehel <address@hidden>
ivy.el (ivy-read): Fix bad refactor
Don't move out (setq ivy-last ...) out of the let block. It first
needs to be captured by `ivy-recursive-last'.
---
ivy.el | 60 ++++++++++++++++++++++++++++++------------------------------
1 file changed, 30 insertions(+), 30 deletions(-)
diff --git a/ivy.el b/ivy.el
index 4111b4d..83750b2 100644
--- a/ivy.el
+++ b/ivy.el
@@ -1969,41 +1969,41 @@ CALLER is a symbol to uniquely identify the caller to
`ivy-read'.
It is used, along with COLLECTION, to determine which
customizations apply to the current completion session."
(setq caller (or caller this-command))
- (setq ivy-last
- (make-ivy-state
- :prompt prompt
- :collection collection
- :predicate predicate
- :require-match require-match
- :initial-input initial-input
- :history history
- :preselect preselect
- :keymap keymap
- :update-fn (if (eq update-fn 'auto)
- (lambda ()
- (funcall (ivy--get-action ivy-last)
- (ivy-state-current ivy-last)))
- update-fn)
- :sort sort
- :action (ivy--compute-extra-actions action caller)
- :multi-action multi-action
- :frame (selected-frame)
- :window (selected-window)
- :buffer (current-buffer)
- :unwind unwind
- :re-builder re-builder
- :matcher matcher
- :dynamic-collection dynamic-collection
- :display-transformer-fn (plist-get ivy--display-transformers-list
caller)
- :directory default-directory
- :caller caller
- :def def))
- (ivy--reset-state ivy-last)
(let* ((ivy-recursive-last (and (active-minibuffer-window) ivy-last))
(ivy--display-function
(when (or ivy-recursive-last
(not (window-minibuffer-p)))
(ivy-alist-setting ivy-display-functions-alist caller))))
+ (setq ivy-last
+ (make-ivy-state
+ :prompt prompt
+ :collection collection
+ :predicate predicate
+ :require-match require-match
+ :initial-input initial-input
+ :history history
+ :preselect preselect
+ :keymap keymap
+ :update-fn (if (eq update-fn 'auto)
+ (lambda ()
+ (funcall (ivy--get-action ivy-last)
+ (ivy-state-current ivy-last)))
+ update-fn)
+ :sort sort
+ :action (ivy--compute-extra-actions action caller)
+ :multi-action multi-action
+ :frame (selected-frame)
+ :window (selected-window)
+ :buffer (current-buffer)
+ :unwind unwind
+ :re-builder re-builder
+ :matcher matcher
+ :dynamic-collection dynamic-collection
+ :display-transformer-fn (plist-get ivy--display-transformers-list
caller)
+ :directory default-directory
+ :caller caller
+ :def def))
+ (ivy--reset-state ivy-last)
(unwind-protect
(minibuffer-with-setup-hook
#'ivy--minibuffer-setup
- [elpa] master ebac0e9 352/399: ivy.el (ivy--compute-extra-actions): Extract, (continued)
- [elpa] master ebac0e9 352/399: ivy.el (ivy--compute-extra-actions): Extract, Oleh Krehel, 2019/07/20
- [elpa] master bae8e46 361/399: ivy.el (ivy--magic-file-doubleslash-directory): Cd remote "/" on "//", Oleh Krehel, 2019/07/20
- [elpa] master a87bdd2 358/399: ivy.el (ivy-read): Refactor, Oleh Krehel, 2019/07/20
- [elpa] master 5e1c468 357/399: ivy.el (ivy--cleanup): Extract, Oleh Krehel, 2019/07/20
- [elpa] master 520fd83 360/399: ivy.el (ivy-read): Simplify, Oleh Krehel, 2019/07/20
- [elpa] master 2d22e05 363/399: doc/ivy.org: Add more info on TRAMP, Oleh Krehel, 2019/07/20
- [elpa] master 180d329 365/399: swiper.el (swiper--re-builder): Improve for char-fold-to-regexp, Oleh Krehel, 2019/07/20
- [elpa] master 4e9e310 368/399: ivy.el (ivy-read): Fix swiper-query-replace not working, Oleh Krehel, 2019/07/20
- [elpa] master a0b71a1 362/399: ivy.el (ivy--magic-tilde-directory): Cd remote "~" on "~", Oleh Krehel, 2019/07/20
- [elpa] master 3af75cf 364/399: swiper.el (swiper--positive-regexps): Extract, Oleh Krehel, 2019/07/20
- [elpa] master 916e281 367/399: ivy.el (ivy-read): Fix bad refactor,
Oleh Krehel <=
- [elpa] master 1ea4ebb 370/399: Fix minor typo, Oleh Krehel, 2019/07/20
- [elpa] master 2fa7cec 366/399: ivy-test.el (swiper--re-builder): Add test, Oleh Krehel, 2019/07/20
- [elpa] master 57e77a5 372/399: counsel.el (counsel-git-log-split-string-re): Change., Oleh Krehel, 2019/07/20
- [elpa] master 72a827a 373/399: counsel.el (counsel-git-log): Add additional action., Oleh Krehel, 2019/07/20
- [elpa] master 259cf07 374/399: Fix ivy-previous-line-or-history, Oleh Krehel, 2019/07/20
- [elpa] master d91f61d 378/399: counsel.el (counsel--split-string): Extract, Oleh Krehel, 2019/07/20
- [elpa] master e858b10 371/399: Add autoload for various commands, Oleh Krehel, 2019/07/20
- [elpa] master 75f4146 377/399: ivy.el (ivy-occur-revert-buffer): Stay on the same line, Oleh Krehel, 2019/07/20
- [elpa] master 3ec81dc 369/399: ivy-test.el (swiper--re-builder-char-fold): Split away, Oleh Krehel, 2019/07/20
- [elpa] master 98127be 375/399: ivy.el (ivy-format-functions-alist): Fix defcustom type, Oleh Krehel, 2019/07/20