- (if (string-match "/[^/]+\\'" file)
- ;; This is needed on NT's and stuff.
- (setq leaf (substring file (1+ (match-beginning 0)))
- path (substring file 0 (1+ (match-beginning 0))))
- ;; Fall back on this.
- (setq leaf (file-name-nondirectory file)
- path (file-name-directory file)))
+ (if full
+ ;; Do complete translation.
+ (setq leaf (copy-sequence file)
+ path "")
+ ;; We translate -- but only the file name. We leave the directory
+ ;; alone.
+ (if (string-match "/[^/]+\\'" file)
+ ;; This is needed on NT's and stuff.
+ (setq leaf (substring file (1+ (match-beginning 0)))
+ path (substring file 0 (1+ (match-beginning 0))))
+ ;; Fall back on this.
+ (setq leaf (file-name-nondirectory file)
+ path (file-name-directory file))))