summaryrefslogtreecommitdiff
path: root/gtk/gtkfilechooserdefault.c
diff options
context:
space:
mode:
authorJonathan Blandford <jrb@gnome.org>2004-03-15 14:10:45 +0000
committerJonathan Blandford <jrb@src.gnome.org>2004-03-15 14:10:45 +0000
commit486fc4fe4560b8cee334157790b9147e92d008ff (patch)
tree07655a219a8887d498da3411b4e3caa2331d236e /gtk/gtkfilechooserdefault.c
parent4d32d9024b384a926987b46516103d7b6b240fa2 (diff)
downloadgtk+-486fc4fe4560b8cee334157790b9147e92d008ff.tar.gz
implement correctly. (completion_match_func): Allow surpressing popdowns.
Mon Mar 15 08:48:48 2004 Jonathan Blandford <jrb@gnome.org> * gtk/gtkfilechooserentry.c (match_selected_callback): implement correctly. (completion_match_func): Allow surpressing popdowns. (maybe_append_seperator_to_path): New function to add a separator item to a display_name. Bad hack. (check_completion_callback): Implement select-ahead as an idle. (add_completion_idle): new function to handle select-ahead (gtk_file_chooser_entry_do_insert_text): starf the select-ahead idle. (gtk_file_chooser_entry_focus): Override tab for completion. (gtk_file_chooser_entry_activate): commit select_ahead when activated. * gtk/gtkfilechooserdefault.c (location_popup_handler): grab the appropriate widget for the mode.
Diffstat (limited to 'gtk/gtkfilechooserdefault.c')
-rw-r--r--gtk/gtkfilechooserdefault.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/gtk/gtkfilechooserdefault.c b/gtk/gtkfilechooserdefault.c
index 88ea7dfd41..953334777a 100644
--- a/gtk/gtkfilechooserdefault.c
+++ b/gtk/gtkfilechooserdefault.c
@@ -5025,7 +5025,17 @@ location_popup_handler (GtkFileChooserDefault *impl)
{
if (update_from_entry (impl, GTK_WINDOW (dialog), GTK_FILE_CHOOSER_ENTRY (entry)))
{
- gtk_widget_grab_focus (impl->browse_files_tree_view);
+ if (impl->action == GTK_FILE_CHOOSER_ACTION_OPEN
+ || impl->action == GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER)
+ {
+ gtk_widget_grab_focus (impl->browse_files_tree_view);
+ }
+ else
+ {
+ g_assert (impl->action == GTK_FILE_CHOOSER_ACTION_OPEN
+ || impl->action == GTK_FILE_CHOOSER_ACTION_SAVE);
+ gtk_widget_grab_focus (impl->save_file_name_entry);
+ }
refocus = FALSE;
}
}