summaryrefslogtreecommitdiff
path: root/gtk/gtkfilechooserentry.c
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2004-10-06 18:20:03 +0000
committerMatthias Clasen <matthiasc@src.gnome.org>2004-10-06 18:20:03 +0000
commit5fde6ffa0b70c29307dceffbc19c6dd6ba288728 (patch)
tree845609dc4e4edcf2743bd7363a750bb003886af9 /gtk/gtkfilechooserentry.c
parent68b72ab7f85a3c12a7c25327fd71e46ca75b0be3 (diff)
downloadgtk+-5fde6ffa0b70c29307dceffbc19c6dd6ba288728.tar.gz
Pop up the completions again after tab. (#147700, Jens Bech Madsen)
2004-10-06 Matthias Clasen <mclasen@redhat.com> * gtk/gtkfilechooserentry.c (gtk_file_chooser_entry_focus): Pop up the completions again after tab. (#147700, Jens Bech Madsen)
Diffstat (limited to 'gtk/gtkfilechooserentry.c')
-rw-r--r--gtk/gtkfilechooserentry.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/gtk/gtkfilechooserentry.c b/gtk/gtkfilechooserentry.c
index 4d9a098560..18ee32b4bd 100644
--- a/gtk/gtkfilechooserentry.c
+++ b/gtk/gtkfilechooserentry.c
@@ -665,11 +665,16 @@ gtk_file_chooser_entry_focus (GtkWidget *widget,
(GTK_WIDGET_HAS_FOCUS (widget)) &&
(! control_pressed))
{
+ gint pos = 0;
+
if (chooser_entry->has_completion)
- {
- gtk_editable_set_position (GTK_EDITABLE (widget),
- GTK_ENTRY (widget)->text_length);
- }
+ gtk_editable_set_position (GTK_EDITABLE (widget),
+ GTK_ENTRY (widget)->text_length);
+ /* Trigger the completion window to pop up again by a
+ * zero-length insertion, a bit of a hack.
+ */
+ gtk_editable_insert_text (GTK_EDITABLE (widget), "", -1, &pos);
+
return TRUE;
}
else