changeset 71803:d35d3efc3d99

(ido-copy-current-file-name): Use buffer-name if buffer-file-name is nil.
author Kim F. Storm <storm@cua.dk>
date Tue, 11 Jul 2006 20:13:59 +0000
parents a346a15d3ed9
children 1a7b37f82a06
files lisp/ido.el
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ido.el	Tue Jul 11 20:13:40 2006 +0000
+++ b/lisp/ido.el	Tue Jul 11 20:13:59 2006 +0000
@@ -2895,7 +2895,8 @@
   "Insert file name of current buffer.
 If repeated, insert text from buffer instead."
   (interactive "P")
-  (let* ((bfname (buffer-file-name ido-entry-buffer))
+  (let* ((bfname (or (buffer-file-name ido-entry-buffer)
+		     (buffer-name ido-entry-buffer)))
 	 (name (and bfname (file-name-nondirectory bfname))))
     (when name
       (setq ido-text-init