emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] Changes to emacs/lisp/ido.el


From: Kim F. Storm
Subject: [Emacs-diffs] Changes to emacs/lisp/ido.el
Date: Wed, 17 May 2006 21:25:59 +0000

Index: emacs/lisp/ido.el
diff -u emacs/lisp/ido.el:1.93 emacs/lisp/ido.el:1.94
--- emacs/lisp/ido.el:1.93      Thu Apr  6 10:35:22 2006
+++ emacs/lisp/ido.el   Wed May 17 21:25:59 2006
@@ -1778,7 +1778,7 @@
   "Perform the `ido-read-buffer' and `ido-read-file-name' functions.
 Return the name of a buffer or file selected.
 PROMPT is the prompt to give to the user.
-DEFAULT if given is the default directory to start with.
+DEFAULT if given is the default item to start with.
 If REQUIRE-MATCH is non-nil, an existing file must be selected.
 If INITIAL is non-nil, it specifies the initial input string."
   (let
@@ -1822,7 +1822,10 @@
              (cond
               ((eq item 'buffer)
                (if (bufferp default) (buffer-name default) default))
-              ((stringp default) default)
+              ((stringp default)
+               (if (memq item '(file dir))
+                   (file-name-nondirectory default)
+                 default))
               ((eq item 'file)
                (and ido-enable-last-directory-history
                     (let ((d (assoc ido-current-directory 
ido-last-directory-list)))




reply via email to

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