Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
d2b66acf
Commit
d2b66acf
authored
Sep 20, 2008
by
Glenn Morris
Browse files
(Qdelete_by_moving_to_trash): New Lisp_Object.
(syms_of_fileio): Add Qdelete_by_moving_to_trash.
parent
11041c99
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
2 deletions
+7
-2
src/ChangeLog
src/ChangeLog
+3
-1
src/fileio.c
src/fileio.c
+4
-1
No files found.
src/ChangeLog
View file @
d2b66acf
...
...
@@ -5,7 +5,9 @@
2008-09-20 Glenn Morris <rgm@gnu.org>
* fileio.c (Frename_file): Avoid copying to trash if a rename involves
* fileio.c (Qdelete_by_moving_to_trash): New Lisp_Object.
(syms_of_fileio): Add Qdelete_by_moving_to_trash.
(Frename_file): Avoid copying to trash if a rename involves
a delete. (Bug#964).
2008-09-20 Eli Zaretskii <eliz@gnu.org>
...
...
src/fileio.c
View file @
d2b66acf
...
...
@@ -201,6 +201,8 @@ int write_region_inhibit_fsync;
Fdelete_directory. */
int delete_by_moving_to_trash;
Lisp_Object Qdelete_by_moving_to_trash;
/* Lisp function for moving files to trash. */
Lisp_Object Qmove_file_to_trash;
...
...
@@ -2246,7 +2248,7 @@ This is what happens in interactive use with M-x. */)
Qt, Qt);
count = SPECPDL_INDEX ();
specbind (
intern ("
delete
-
by
-
moving
-
to
-
trash
")
, Qnil);
specbind (
Q
delete
_
by
_
moving
_
to
_
trash, Qnil);
Fdelete_file (file);
unbind_to (count, Qnil);
}
...
...
@@ -5669,6 +5671,7 @@ A non-nil value may result in data loss! */);
When non-nil, the function `move-file-to-trash' will be used by
`delete-file' and `delete-directory'. */);
delete_by_moving_to_trash = 0;
Qdelete_by_moving_to_trash = intern ("delete-by-moving-to-trash");
Qmove_file_to_trash = intern ("move-file-to-trash");
staticpro (&Qmove_file_to_trash);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment