aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lisp/files.el8
1 files changed, 4 insertions, 4 deletions
diff --git a/lisp/files.el b/lisp/files.el
index ad032832ec5..0f0c7d1559a 100644
--- a/lisp/files.el
+++ b/lisp/files.el
@@ -7393,7 +7393,10 @@ Otherwise, trash FILENAME using the freedesktop.org conventions,
7393 like the GNOME, KDE and XFCE desktop environments. Emacs only 7393 like the GNOME, KDE and XFCE desktop environments. Emacs only
7394 moves files to \"home trash\", ignoring per-volume trashcans." 7394 moves files to \"home trash\", ignoring per-volume trashcans."
7395 (interactive "fMove file to trash: ") 7395 (interactive "fMove file to trash: ")
7396 (cond (trash-directory 7396 ;; If `system-move-file-to-trash' is defined, use it.
7397 (cond ((fboundp 'system-move-file-to-trash)
7398 (system-move-file-to-trash filename))
7399 (trash-directory
7397 ;; If `trash-directory' is non-nil, move the file there. 7400 ;; If `trash-directory' is non-nil, move the file there.
7398 (let* ((trash-dir (expand-file-name trash-directory)) 7401 (let* ((trash-dir (expand-file-name trash-directory))
7399 (fn (directory-file-name (expand-file-name filename))) 7402 (fn (directory-file-name (expand-file-name filename)))
@@ -7412,9 +7415,6 @@ Otherwise, trash FILENAME using the freedesktop.org conventions,
7412 (setq new-fn (car (find-backup-file-name new-fn))))) 7415 (setq new-fn (car (find-backup-file-name new-fn)))))
7413 (let (delete-by-moving-to-trash) 7416 (let (delete-by-moving-to-trash)
7414 (rename-file fn new-fn)))) 7417 (rename-file fn new-fn))))
7415 ;; If `system-move-file-to-trash' is defined, use it.
7416 ((fboundp 'system-move-file-to-trash)
7417 (system-move-file-to-trash filename))
7418 ;; Otherwise, use the freedesktop.org method, as specified at 7418 ;; Otherwise, use the freedesktop.org method, as specified at
7419 ;; http://freedesktop.org/wiki/Specifications/trash-spec 7419 ;; http://freedesktop.org/wiki/Specifications/trash-spec
7420 (t 7420 (t