From c384b2528d9d513ab9f7eeffc159d3b1785d0073 Mon Sep 17 00:00:00 2001 From: Alexander Schwinn Date: Mon, 26 Mar 2018 23:14:12 +0200 Subject: [PATCH] Thunar confuses files (bug #12435) --- thunar/thunar-list-model.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/thunar/thunar-list-model.c b/thunar/thunar-list-model.c index 6e408845..91e9fd11 100644 --- a/thunar/thunar-list-model.c +++ b/thunar/thunar-list-model.c @@ -1159,11 +1159,7 @@ thunar_list_model_file_changed (ThunarFileMonitor *file_monitor, /* generate the iterator for this row */ GTK_TREE_ITER_INIT (iter, store->stamp, row); - /* notify the view that it has to redraw the file */ _thunar_assert (pos_before == g_sequence_iter_get_position (row)); - path = gtk_tree_path_new_from_indices (pos_before, -1); - gtk_tree_model_row_changed (GTK_TREE_MODEL (store), path, &iter); - gtk_tree_path_free (path); /* check if the sorting changed */ g_sequence_sort_changed (row, thunar_list_model_cmp_func, store); @@ -1197,6 +1193,11 @@ thunar_list_model_file_changed (ThunarFileMonitor *file_monitor, gtk_tree_model_rows_reordered (GTK_TREE_MODEL (store), path, NULL, new_order); gtk_tree_path_free (path); + /* notify the view that it has to redraw the file */ + path = gtk_tree_path_new_from_indices (pos_before, -1); + gtk_tree_model_row_changed (GTK_TREE_MODEL (store), path, &iter); + gtk_tree_path_free (path); + /* clean up if we used the heap */ if (G_UNLIKELY (length >= 2000)) g_free (new_order); -- 2.11.0