[nautilus] window-slot: don't invalidate when force reload



commit cd0d78a6b5bcfc977e2921278487aeef44f94512
Author: Carlos Soriano <csoriano gnome org>
Date:   Thu Sep 3 12:23:05 2015 +0200

    window-slot: don't invalidate when force reload
    
    Some directory types like the desktop even request
    explicitly to do not so, and other like the vfs already
    invalidate all attributes. So let the directory type
    itself to whatever is necessary to invalidate its file.

 libnautilus-private/nautilus-search-directory.c |    5 +++++
 src/nautilus-window-slot.c                      |    3 ---
 2 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/libnautilus-private/nautilus-search-directory.c b/libnautilus-private/nautilus-search-directory.c
index d50c418..86cf2bf 100644
--- a/libnautilus-private/nautilus-search-directory.c
+++ b/libnautilus-private/nautilus-search-directory.c
@@ -636,6 +636,7 @@ static void
 search_force_reload (NautilusDirectory *directory)
 {
        NautilusSearchDirectory *search;
+        NautilusFile *file;
 
        search = NAUTILUS_SEARCH_DIRECTORY (directory);
 
@@ -648,6 +649,10 @@ search_force_reload (NautilusDirectory *directory)
        /* Remove file monitors */
        reset_file_list (search);
        stop_search (search);
+
+       file = nautilus_directory_get_corresponding_file (directory);
+       nautilus_file_invalidate_all_attributes (file);
+       nautilus_file_unref (file);
 }
 
 static gboolean
diff --git a/src/nautilus-window-slot.c b/src/nautilus-window-slot.c
index 1119761..e9244d8 100644
--- a/src/nautilus-window-slot.c
+++ b/src/nautilus-window-slot.c
@@ -852,9 +852,6 @@ begin_location_change (NautilusWindowSlot         *slot,
 
        if (force_reload) {
                nautilus_directory_force_reload (directory);
-               file = nautilus_directory_get_corresponding_file (directory);
-               nautilus_file_invalidate_all_attributes (file);
-               nautilus_file_unref (file);
        }
 
         nautilus_directory_unref (directory);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]