summaryrefslogtreecommitdiff
path: root/gtk/gtkfilesystemmodel.c
diff options
context:
space:
mode:
authorSergey Orlov <wasp82@bk.ru>2010-08-24 13:17:15 -0500
committerFederico Mena Quintero <federico@novell.com>2010-08-24 17:09:37 -0500
commita676f9dada40f43de5ccf36a66c37fa7955aaa7f (patch)
tree0af487bd8974295db39caf45fae728f7f4075e1d /gtk/gtkfilesystemmodel.c
parent72fad93587a4f4c6d60e613e86b4a85e0f1f31d6 (diff)
downloadgtk+-a676f9dada40f43de5ccf36a66c37fa7955aaa7f.tar.gz
bgo#614006 - GtkFileSystemModel - Make sure to generate node IDs are valid for new files
When a file was inserted during the period that the editable row was active, the node IDs would not get updated correctly. Signed-off-by: Federico Mena Quintero <federico@novell.com>
Diffstat (limited to 'gtk/gtkfilesystemmodel.c')
-rw-r--r--gtk/gtkfilesystemmodel.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/gtk/gtkfilesystemmodel.c b/gtk/gtkfilesystemmodel.c
index 5b29b9bc39..c6532c136f 100644
--- a/gtk/gtkfilesystemmodel.c
+++ b/gtk/gtkfilesystemmodel.c
@@ -1777,7 +1777,10 @@ _gtk_file_system_model_update_file (GtkFileSystemModel *model,
id = node_get_for_file (model, file);
if (id == 0)
- add_file (model, file, info);
+ {
+ add_file (model, file, info);
+ id = node_get_for_file (model, file);
+ }
node = get_node (model, id);