summaryrefslogtreecommitdiff
path: root/gtk/gtkfilesystemmodel.c
diff options
context:
space:
mode:
authorFederico Mena Quintero <federico@gnome.org>2012-10-31 20:54:02 -0600
committerFederico Mena Quintero <federico@gnome.org>2012-10-31 20:54:02 -0600
commitf39f5749148e240ea9b72f4806c1b01e85e504d7 (patch)
treeff2fb52ba0c2b2564530c37afce87d87230142a2 /gtk/gtkfilesystemmodel.c
parent281c592ea9485d5cb53ee7073b2a7588db33a8a2 (diff)
downloadgtk+-f39f5749148e240ea9b72f4806c1b01e85e504d7.tar.gz
Remove argument to _gtk_file_system_model_update_file() that should not be part of the internal API
Signed-off-by: Federico Mena Quintero <federico@gnome.org>
Diffstat (limited to 'gtk/gtkfilesystemmodel.c')
-rw-r--r--gtk/gtkfilesystemmodel.c18
1 files changed, 11 insertions, 7 deletions
diff --git a/gtk/gtkfilesystemmodel.c b/gtk/gtkfilesystemmodel.c
index 9f738b90f7..90a4db2d5c 100644
--- a/gtk/gtkfilesystemmodel.c
+++ b/gtk/gtkfilesystemmodel.c
@@ -184,6 +184,9 @@ struct _GtkFileSystemModelClass
void (*finished_loading) (GtkFileSystemModel *model, GError *error);
};
+static guint node_get_for_file (GtkFileSystemModel *model,
+ GFile *file);
+
static void add_file (GtkFileSystemModel *model,
GFile *file,
GFileInfo *info);
@@ -1189,13 +1192,19 @@ gtk_file_system_model_query_done (GObject * object,
GtkFileSystemModel *model = data; /* only a valid pointer if not cancelled */
GFile *file = G_FILE (object);
GFileInfo *info;
+ guint id;
info = g_file_query_info_finish (file, res, NULL);
if (info == NULL)
return;
gdk_threads_enter ();
- _gtk_file_system_model_update_file (model, file, info, TRUE);
+
+ _gtk_file_system_model_update_file (model, file, info);
+
+ id = node_get_for_file (model, file);
+ gtk_file_system_model_sort_node (model, id);
+
gdk_threads_leave ();
}
@@ -1852,7 +1861,6 @@ remove_file (GtkFileSystemModel *model,
* @model: the model
* @file: the file
* @info: the new file info
- * @requires_resort: FIXME: get rid of this argument
*
* Tells the file system model that the file changed and that the
* new @info should be used for it now. If the file is not part of
@@ -1861,8 +1869,7 @@ remove_file (GtkFileSystemModel *model,
void
_gtk_file_system_model_update_file (GtkFileSystemModel *model,
GFile *file,
- GFileInfo *info,
- gboolean requires_resort)
+ GFileInfo *info)
{
FileModelNode *node;
guint i, id;
@@ -1894,9 +1901,6 @@ _gtk_file_system_model_update_file (GtkFileSystemModel *model,
if (node->visible)
emit_row_changed_for_node (model, id);
-
- if (requires_resort)
- gtk_file_system_model_sort_node (model, id);
}
/**