aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Albinus2007-11-24 15:40:09 +0000
committerMichael Albinus2007-11-24 15:40:09 +0000
commitd9e43b70c686200c146bf0762a9f0b97ff309245 (patch)
tree0bc8af1e4358a18d281184166cf5db49fd6c7562
parent95ec6ea4b990b9ec424feee973a3a5ae3f8b23d0 (diff)
downloademacs-d9e43b70c686200c146bf0762a9f0b97ff309245.tar.gz
emacs-d9e43b70c686200c146bf0762a9f0b97ff309245.zip
* ido.el (ido-file-name-all-completions-1): Check for fboundp of
`tramp-completion-mode-p' as it is in Tramp 2.1. Let-bind `tramp-completion-mode'.
-rw-r--r--lisp/ChangeLog6
-rw-r--r--lisp/ido.el29
2 files changed, 21 insertions, 14 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 6bf2aeee381..e685cf56091 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,9 @@
12007-11-24 Michael Albinus <michael.albinus@gmx.de>
2
3 * ido.el (ido-file-name-all-completions-1): Check for fboundp of
4 `tramp-completion-mode-p' as it is in Tramp 2.1. Let-bind
5 `tramp-completion-mode'.
6
12007-11-24 Thien-Thi Nguyen <ttn@gnuvola.org> 72007-11-24 Thien-Thi Nguyen <ttn@gnuvola.org>
2 8
3 * vc-git.el (vc-git-show-log-entry): New func. 9 * vc-git.el (vc-git-show-log-entry): New func.
diff --git a/lisp/ido.el b/lisp/ido.el
index af8936b86d9..3801934fc3e 100644
--- a/lisp/ido.el
+++ b/lisp/ido.el
@@ -3373,24 +3373,25 @@ for first matching file."
3373 ;; Caller must have done that if necessary. 3373 ;; Caller must have done that if necessary.
3374 3374
3375 ((and ido-enable-tramp-completion 3375 ((and ido-enable-tramp-completion
3376 (or (fboundp 'tramp-completion-mode) 3376 (or (fboundp 'tramp-completion-mode-p)
3377 (require 'tramp nil t)) 3377 (require 'tramp nil t))
3378 (string-match "\\`/[^/]+[:@]\\'" dir)) 3378 (string-match "\\`/[^/]+[:@]\\'" dir))
3379 ;; Strip method:user@host: part of tramp completions. 3379 ;; Strip method:user@host: part of tramp completions.
3380 ;; Tramp completions do not include leading slash. 3380 ;; Tramp completions do not include leading slash.
3381 (let ((len (1- (length dir))) 3381 (let* ((len (1- (length dir)))
3382 (compl 3382 (tramp-completion-mode t)
3383 (or (file-name-all-completions "" dir) 3383 (compl
3384 ;; work around bug in ange-ftp. 3384 (or (file-name-all-completions "" dir)
3385 ;; /ftp:user@host: => nil 3385 ;; work around bug in ange-ftp.
3386 ;; /ftp:user@host:./ => ok 3386 ;; /ftp:user@host: => nil
3387 (and 3387 ;; /ftp:user@host:./ => ok
3388 (not (string= "/ftp:" dir)) 3388 (and
3389 (tramp-tramp-file-p dir) 3389 (not (string= "/ftp:" dir))
3390 (fboundp 'tramp-ftp-file-name-p) 3390 (tramp-tramp-file-p dir)
3391 (funcall 'tramp-ftp-file-name-p dir) 3391 (fboundp 'tramp-ftp-file-name-p)
3392 (string-match ":\\'" dir) 3392 (funcall 'tramp-ftp-file-name-p dir)
3393 (file-name-all-completions "" (concat dir "./")))))) 3393 (string-match ":\\'" dir)
3394 (file-name-all-completions "" (concat dir "./"))))))
3394 (if (and compl 3395 (if (and compl
3395 (> (length (car compl)) len) 3396 (> (length (car compl)) len)
3396 (string= (substring (car compl) 0 len) (substring dir 1))) 3397 (string= (substring (car compl) 0 len) (substring dir 1)))