diff options
author | Christian Neumair <chris@gnome-de.org> | 2005-10-19 18:09:56 +0000 |
---|---|---|
committer | Christian Neumair <cneumair@src.gnome.org> | 2005-10-19 18:09:56 +0000 |
commit | 27084cd325d8a2fbb986bc1a6dbb3b053e715a85 (patch) | |
tree | 5da78407995d219958ccf825fb919dec44e6a193 | |
parent | 61676b11547b4125d503a73ed8cc9f57091c4297 (diff) | |
download | nautilus-27084cd325d8a2fbb986bc1a6dbb3b053e715a85.tar.gz |
Don't update bookmark when its target file is trashed. Fixes #162787.
2005-10-19 Christian Neumair <chris@gnome-de.org>
* libnautilus-private/nautilus-bookmark.c:
(bookmark_file_changed_callback):
Don't update bookmark when its target file is trashed. Fixes #162787.
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | libnautilus-private/nautilus-bookmark.c | 8 |
2 files changed, 11 insertions, 3 deletions
@@ -1,3 +1,9 @@ +2005-10-19 Christian Neumair <chris@gnome-de.org> + + * libnautilus-private/nautilus-bookmark.c: + (bookmark_file_changed_callback): + Don't update bookmark when its target file is trashed. Fixes #162787. + 2005-10-18 Christian Neumair <chris@gnome-de.org> * src/file-manager/fm-directory-view.c: diff --git a/libnautilus-private/nautilus-bookmark.c b/libnautilus-private/nautilus-bookmark.c index c71e3cf55..0cc35510a 100644 --- a/libnautilus-private/nautilus-bookmark.c +++ b/libnautilus-private/nautilus-bookmark.c @@ -353,7 +353,8 @@ bookmark_file_changed_callback (NautilusFile *file, NautilusBookmark *bookmark) should_emit_contents_changed_signal = FALSE; file_uri = nautilus_file_get_uri (file); - if (!gnome_vfs_uris_match (bookmark->details->uri, file_uri)) { + if (!gnome_vfs_uris_match (bookmark->details->uri, file_uri) && + !nautilus_file_is_in_trash (file)) { g_free (bookmark->details->uri); bookmark->details->uri = file_uri; should_emit_contents_changed_signal = TRUE; @@ -361,8 +362,9 @@ bookmark_file_changed_callback (NautilusFile *file, NautilusBookmark *bookmark) g_free (file_uri); } - if (nautilus_file_is_gone (file)) { - /* The file we were monitoring has been deleted, + if (nautilus_file_is_gone (file) || + nautilus_file_is_in_trash (file)) { + /* The file we were monitoring has been trashed, deleted, * or moved in a way that we didn't notice. Make * a spanking new NautilusFile object for this * location so if a new file appears in this place |