diff options
-rw-r--r-- | gtk/gtkfilechooserentry.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/gtk/gtkfilechooserentry.c b/gtk/gtkfilechooserentry.c index 720eb1e533..98ecd24c71 100644 --- a/gtk/gtkfilechooserentry.c +++ b/gtk/gtkfilechooserentry.c @@ -233,23 +233,25 @@ gtk_file_chooser_entry_dispose (GObject *object) /* Match functions for the GtkEntryCompletion */ static gboolean match_selected_callback (GtkEntryCompletion *completion, - GtkTreeModel *model, - GtkTreeIter *iter, - GtkFileChooserEntry *chooser_entry) + GtkTreeModel *model, + GtkTreeIter *iter, + GtkFileChooserEntry *chooser_entry) { char *path; - + gint pos; + gtk_tree_model_get (model, iter, - FULL_PATH_COLUMN, &path, + FULL_PATH_COLUMN, &path, -1); gtk_editable_delete_text (GTK_EDITABLE (chooser_entry), - 0, + 0, gtk_editable_get_position (GTK_EDITABLE (chooser_entry))); + pos = 0; gtk_editable_insert_text (GTK_EDITABLE (chooser_entry), - path, - 0, - NULL); + path, + -1, + &pos); g_free (path); |