summaryrefslogtreecommitdiff
path: root/gtk/gtkfilechooserembed.h
diff options
context:
space:
mode:
authorFederico Mena Quintero <federico@ximian.com>2004-03-05 00:10:59 +0000
committerFederico Mena Quintero <federico@src.gnome.org>2004-03-05 00:10:59 +0000
commitd64c7c08a8e742158d49a129f8b68215dd8d2eff (patch)
tree8b208d81b5b5219737efd74e1f8446ffe3b02c48 /gtk/gtkfilechooserembed.h
parent1810dba3384c18152bf9993467acbf8f36528312 (diff)
downloadgtk+-d64c7c08a8e742158d49a129f8b68215dd8d2eff.tar.gz
New handler. Ask the GtkFileChooser widget if it wants to do something
2004-03-04 Federico Mena Quintero <federico@ximian.com> * gtk/gtkfilechooserdialog.c (response_cb): New handler. Ask the GtkFileChooser widget if it wants to do something special rather than letting us terminate the dialog. (gtk_file_chooser_dialog_init): Connect to "response"; see the comment in the sources to see why we don't override the method in class_init. * gtk/gtkfilechooserembed.h (struct _GtkFileChooserEmbedIface): Added a ::should_respond() method. * gtk/gtkfilechooserembed.c (_gtk_file_chooser_embed_delegate_iface_init): Add a delegate for ::should_respond(). (delegate_should_respond): New delegate. (_gtk_file_chooser_embed_should_respond): New function. * gtk/gtkfilechooserdefault.c (set_list_model, create_file_list): Use dashes in signal names rather than underscores. (gtk_file_chooser_default_init): Hook up our ::should_respond() implementation. (gtk_file_chooser_default_should_respond): Implement. go into a folder rather than responding if we are in File mode and the selected file is a folder. (get_selection): New helper function. (add_bookmark_button_clicked_cb): Use get_selection(). (bookmarks_check_add_sensitivity): Likewise. (gtk_file_chooser_default_get_paths): Likewise. (check_save_entry): New helper function. (gtk_file_chooser_default_get_paths): Use check_save_entry(). (selection_check): Renamed from selection_is_folders(). Now checks whether the selection is empty, all files, all folders. (bookmarks_check_add_sensitivity): Use selection_check().
Diffstat (limited to 'gtk/gtkfilechooserembed.h')
-rw-r--r--gtk/gtkfilechooserembed.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/gtk/gtkfilechooserembed.h b/gtk/gtkfilechooserembed.h
index e41c7f86cc..7c6d6bb31e 100644
--- a/gtk/gtkfilechooserembed.h
+++ b/gtk/gtkfilechooserembed.h
@@ -46,6 +46,8 @@ struct _GtkFileChooserEmbedIface
void (*get_resizable_hints) (GtkFileChooserEmbed *chooser_embed,
gboolean *resize_horizontally,
gboolean *resize_vertically);
+
+ gboolean (*should_respond) (GtkFileChooserEmbed *chooser_embed);
/* Signals
*/
void (*default_size_changed) (GtkFileChooserEmbed *chooser_embed);
@@ -60,6 +62,8 @@ void _gtk_file_chooser_embed_get_resizable_hints (GtkFileChooserEmbed *chooser_
gboolean *resize_horizontally,
gboolean *resize_vertically);
+gboolean _gtk_file_chooser_embed_should_respond (GtkFileChooserEmbed *chooser_embed);
+
void _gtk_file_chooser_embed_delegate_iface_init (GtkFileChooserEmbedIface *iface);
void _gtk_file_chooser_embed_set_delegate (GtkFileChooserEmbed *receiver,
GtkFileChooserEmbed *delegate);