[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master a953af0 19/57: Simplify ivy-partial-or-done
From: |
Oleh Krehel |
Subject: |
[elpa] master a953af0 19/57: Simplify ivy-partial-or-done |
Date: |
Tue, 19 May 2015 14:21:27 +0000 |
branch: master
commit a953af021c064b7a8413360a0dad7d04e5998631
Author: Tassilo Horn <address@hidden>
Commit: Oleh Krehel <address@hidden>
Simplify ivy-partial-or-done
---
ivy.el | 16 ++++++----------
1 files changed, 6 insertions(+), 10 deletions(-)
diff --git a/ivy.el b/ivy.el
index e42f8c3..d130a77 100644
--- a/ivy.el
+++ b/ivy.el
@@ -281,14 +281,10 @@ When ARG is t, exit with current text, ignoring the
candidates."
When called twice in a row, exit the minibuffer with the current
candidate."
(interactive)
- (if (eq this-command last-command)
- (ivy-alt-done)
- (unless (ivy-partial)
- (when (and (eq confirm-nonexistent-file-or-buffer t)
- (memq (ivy-state-collection ivy-last)
- '(read-file-name-internal
- internal-complete-buffer)))
- (ivy-done)))))
+ (or (ivy-partial)
+ (if (eq this-command last-command)
+ (ivy-done)
+ (ivy-alt-done))))
(defun ivy-partial ()
"Complete the minibuffer text as much as possible."
@@ -299,8 +295,8 @@ candidate."
(new (try-completion postfix
(mapcar (lambda (str) (substring str
(string-match postfix str)))
ivy--old-cands))))
- (cond ((eq new t)
- nil)
+ (cond ((eq new t) nil)
+ ((string= new ivy-text) nil)
(new
(delete-region (minibuffer-prompt-end) (point-max))
(setcar (last parts) new)
- [elpa] master 386184b 14/57: Merge ivy--update-fn into ivy-last, (continued)
- [elpa] master 386184b 14/57: Merge ivy--update-fn into ivy-last, Oleh Krehel, 2015/05/19
- [elpa] master c5fce64 05/57: Make "TAB" switch directories properly, Oleh Krehel, 2015/05/19
- [elpa] master 6784185 17/57: Allow to use "^" in swiper, Oleh Krehel, 2015/05/19
- [elpa] master fb3fce9 13/57: Add parents using 'display for `counsel-load-library', Oleh Krehel, 2015/05/19
- [elpa] master 5601653 06/57: Require dired when completing file names, Oleh Krehel, 2015/05/19
- [elpa] master 4a7ba2f 15/57: Try to prevent the resize of minibuffer window, Oleh Krehel, 2015/05/19
- [elpa] master 5a451a9 26/57: ivy.el (ivy-read): Add a re-builder argument, Oleh Krehel, 2015/05/19
- [elpa] master f7fc3ad 11/57: Work around grep-read-files, Oleh Krehel, 2015/05/19
- [elpa] master 056614d 22/57: Rename avy-swiper to swiper-avy, Oleh Krehel, 2015/05/19
- [elpa] master cf292da 23/57: Declare swiper-map, Oleh Krehel, 2015/05/19
- [elpa] master a953af0 19/57: Simplify ivy-partial-or-done,
Oleh Krehel <=
- [elpa] master fe34d2c 10/57: ivy.el (ivy-partial-or-done): Handle empty input, Oleh Krehel, 2015/05/19
- [elpa] master 77abf00 25/57: ivy.el (ivy-backward-kill-word): Add and bind to "M-DEL", Oleh Krehel, 2015/05/19
- [elpa] master 8c936bc 21/57: ivy.el (ivy-use-virtual-buffers): New defcustom, Oleh Krehel, 2015/05/19
- [elpa] master 9b9885d 33/57: ivy.el (ivy-partial-or-done): Fixup, Oleh Krehel, 2015/05/19
- [elpa] master d841418 24/57: Fix the transition from a bad regex to good one, Oleh Krehel, 2015/05/19
- [elpa] master 2ad5fb1 20/57: Add support for virtual buffers, Oleh Krehel, 2015/05/19
- [elpa] master f97622d 30/57: swiper.el (swiper-font-lock-ensure): Ignore fundamental-mode, Oleh Krehel, 2015/05/19
- [elpa] master 6d4f2b3 34/57: Fix the error switching to non-existent buffers, Oleh Krehel, 2015/05/19
- [elpa] master 16eb4a2 31/57: When completing file names, defer to `minibuffer-complete' for "TAB", Oleh Krehel, 2015/05/19
- [elpa] master b63c358 35/57: Properly update virtual buffers for "^ " interaction, Oleh Krehel, 2015/05/19