Merge branch 'wip/corey/filesystemmodel' into 'main'
filesystemmodel: Ignore changes on the parent directory Closes #4233 See merge request GNOME/gtk!5970
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -1 +1,2 @@
|
||||
/subprojects/*/
|
||||
.flatpak-builder/
|
||||
|
||||
@@ -580,7 +580,10 @@ gtk_file_chooser_widget_finalize (GObject *object)
|
||||
stop_loading_and_clear_list_model (impl, FALSE);
|
||||
search_clear_model (impl, FALSE);
|
||||
recent_clear_model (impl, FALSE);
|
||||
g_clear_object (&impl->recent_model);
|
||||
g_clear_object (&impl->search_model);
|
||||
g_clear_object (&impl->model_for_search);
|
||||
g_clear_object (&impl->browse_files_model);
|
||||
|
||||
g_clear_object (&impl->selection_model);
|
||||
g_clear_object (&impl->sort_model);
|
||||
@@ -3961,6 +3964,7 @@ set_list_model (GtkFileChooserWidget *impl,
|
||||
|
||||
set_busy_cursor (impl, TRUE);
|
||||
|
||||
g_clear_object (&impl->browse_files_model);
|
||||
impl->browse_files_model =
|
||||
_gtk_file_system_model_new_for_directory (impl->current_folder, MODEL_ATTRIBUTES);
|
||||
|
||||
|
||||
@@ -747,7 +747,9 @@ gtk_file_system_model_monitor_change (GFileMonitor * monitor,
|
||||
case G_FILE_MONITOR_EVENT_CREATED:
|
||||
case G_FILE_MONITOR_EVENT_CHANGED:
|
||||
case G_FILE_MONITOR_EVENT_ATTRIBUTE_CHANGED:
|
||||
/* We can treat all of these the same way */
|
||||
if (g_file_equal (file, model->dir))
|
||||
return;
|
||||
/* We can treat all children the same way */
|
||||
g_file_query_info_async (file,
|
||||
model->attributes,
|
||||
G_FILE_QUERY_INFO_NONE,
|
||||
|
||||
Reference in New Issue
Block a user