From 9a08196a0b57e83d6faf02bbaee6cf717ef4bc0e Mon Sep 17 00:00:00 2001 From: "Kim F. Storm" Date: Mon, 8 Jul 2002 22:22:12 +0000 Subject: [PATCH] (ido-make-merged-file-list): Move fully matching item to head of list. --- lisp/ChangeLog | 6 ++++++ lisp/ido.el | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 347fa503d0f..28c6463e424 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2002-07-09 Kim F. Storm + + * ido.el (ido-make-merged-file-list): Move fully matching item to + head of list. + (ido-find-common-substring): Return substring instead of t. + 2002-07-08 Juanma Barranquero * info.el (Info-directory-list): Fix docstring. diff --git a/lisp/ido.el b/lisp/ido.el index 97aa0d24a09..049ef96cb08 100644 --- a/lisp/ido.el +++ b/lisp/ido.el @@ -2511,6 +2511,12 @@ for first matching file." res t)))))) (if (and res (not (eq res t))) (setq res (ido-sort-merged-list res auto))) + (when (and (or ido-rotate-temp ido-rotate-file-list-default) + (> (length text) 0)) + (let ((elt (assoc text res))) + (unless (eq elt (car res)) + (setq res (delq elt res)) + (setq res (cons elt res))))) (message nil) res)) -- 2.39.5