# HG changeset patch # User Michael Albinus # Date 1195918809 0 # Node ID 22b18b2eec8e7795adfe7834e1ccc8821e882dbf # Parent 7f36cf0620b3ca8b3af50e253b80c4c378898c52 * 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'. diff -r 7f36cf0620b3 -r 22b18b2eec8e lisp/ChangeLog --- a/lisp/ChangeLog Sat Nov 24 15:32:54 2007 +0000 +++ b/lisp/ChangeLog Sat Nov 24 15:40:09 2007 +0000 @@ -1,3 +1,9 @@ +2007-11-24 Michael Albinus + + * 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'. + 2007-11-24 Thien-Thi Nguyen * vc-git.el (vc-git-show-log-entry): New func. diff -r 7f36cf0620b3 -r 22b18b2eec8e lisp/ido.el --- a/lisp/ido.el Sat Nov 24 15:32:54 2007 +0000 +++ b/lisp/ido.el Sat Nov 24 15:40:09 2007 +0000 @@ -3373,24 +3373,25 @@ ;; Caller must have done that if necessary. ((and ido-enable-tramp-completion - (or (fboundp 'tramp-completion-mode) + (or (fboundp 'tramp-completion-mode-p) (require 'tramp nil t)) (string-match "\\`/[^/]+[:@]\\'" dir)) ;; Strip method:user@host: part of tramp completions. ;; Tramp completions do not include leading slash. - (let ((len (1- (length dir))) - (compl - (or (file-name-all-completions "" dir) - ;; work around bug in ange-ftp. - ;; /ftp:user@host: => nil - ;; /ftp:user@host:./ => ok - (and - (not (string= "/ftp:" dir)) - (tramp-tramp-file-p dir) - (fboundp 'tramp-ftp-file-name-p) - (funcall 'tramp-ftp-file-name-p dir) - (string-match ":\\'" dir) - (file-name-all-completions "" (concat dir "./")))))) + (let* ((len (1- (length dir))) + (tramp-completion-mode t) + (compl + (or (file-name-all-completions "" dir) + ;; work around bug in ange-ftp. + ;; /ftp:user@host: => nil + ;; /ftp:user@host:./ => ok + (and + (not (string= "/ftp:" dir)) + (tramp-tramp-file-p dir) + (fboundp 'tramp-ftp-file-name-p) + (funcall 'tramp-ftp-file-name-p dir) + (string-match ":\\'" dir) + (file-name-all-completions "" (concat dir "./")))))) (if (and compl (> (length (car compl)) len) (string= (substring (car compl) 0 len) (substring dir 1)))