From d40eda7e8774b57a7cbe5a7421c92a51167900cc Mon Sep 17 00:00:00 2001 From: Jonathan Blandford Date: Thu, 26 Feb 2004 23:35:05 +0000 Subject: [PATCH] Add two more folder modes to the enum. Thu Feb 26 18:25:57 2004 Jonathan Blandford * gtk/gtkfilechooser.h (GtkFileChooserAction): Add two more folder modes to the enum. * gtk/gtkfilechooser.c (gtk_file_chooser_set_folder_mode): Remove. (gtk_file_chooser_get_folder_mode): Remove --- ChangeLog | 8 ++ ChangeLog.pre-2-10 | 8 ++ ChangeLog.pre-2-4 | 8 ++ ChangeLog.pre-2-6 | 8 ++ ChangeLog.pre-2-8 | 8 ++ .../gdk-pixbuf/tmpl/gdk-pixbuf-loader.sgml | 60 +++++++-------- .../gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml | 48 ------------ .../reference/gdk-pixbuf/tmpl/gdk-pixbuf.sgml | 40 ++++++++++ docs/reference/gtk/tmpl/gtk-unused.sgml | 16 ++++ docs/reference/gtk/tmpl/gtkcomboboxentry.sgml | 8 ++ docs/reference/gtk/tmpl/gtkfilechooser.sgml | 28 ++----- docs/reference/gtk/tmpl/gtkradiobutton.sgml | 7 ++ docs/reference/gtk/tmpl/gtkradiomenuitem.sgml | 7 ++ docs/reference/gtk/tmpl/gtkrc.sgml | 8 ++ docs/reference/gtk/tmpl/gtkstyle.sgml | 28 +++++++ gtk/gtkfilechooser.c | 55 +------------- gtk/gtkfilechooser.h | 7 +- gtk/gtkfilechooserdefault.c | 73 ++++++------------- gtk/gtkfilechooserwidget.c | 1 - 19 files changed, 222 insertions(+), 204 deletions(-) diff --git a/ChangeLog b/ChangeLog index c88616bb29..12ffe643cc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +Thu Feb 26 18:25:57 2004 Jonathan Blandford + + * gtk/gtkfilechooser.h (GtkFileChooserAction): Add two more folder + modes to the enum. + + * gtk/gtkfilechooser.c (gtk_file_chooser_set_folder_mode): Remove. + (gtk_file_chooser_get_folder_mode): Remove + Thu Feb 26 17:29:04 2004 Owen Taylor * gdk/x11/gdkevents-x11.c (gdk_wm_protocols_filter): Return diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index c88616bb29..12ffe643cc 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,11 @@ +Thu Feb 26 18:25:57 2004 Jonathan Blandford + + * gtk/gtkfilechooser.h (GtkFileChooserAction): Add two more folder + modes to the enum. + + * gtk/gtkfilechooser.c (gtk_file_chooser_set_folder_mode): Remove. + (gtk_file_chooser_get_folder_mode): Remove + Thu Feb 26 17:29:04 2004 Owen Taylor * gdk/x11/gdkevents-x11.c (gdk_wm_protocols_filter): Return diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index c88616bb29..12ffe643cc 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,11 @@ +Thu Feb 26 18:25:57 2004 Jonathan Blandford + + * gtk/gtkfilechooser.h (GtkFileChooserAction): Add two more folder + modes to the enum. + + * gtk/gtkfilechooser.c (gtk_file_chooser_set_folder_mode): Remove. + (gtk_file_chooser_get_folder_mode): Remove + Thu Feb 26 17:29:04 2004 Owen Taylor * gdk/x11/gdkevents-x11.c (gdk_wm_protocols_filter): Return diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index c88616bb29..12ffe643cc 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,11 @@ +Thu Feb 26 18:25:57 2004 Jonathan Blandford + + * gtk/gtkfilechooser.h (GtkFileChooserAction): Add two more folder + modes to the enum. + + * gtk/gtkfilechooser.c (gtk_file_chooser_set_folder_mode): Remove. + (gtk_file_chooser_get_folder_mode): Remove + Thu Feb 26 17:29:04 2004 Owen Taylor * gdk/x11/gdkevents-x11.c (gdk_wm_protocols_filter): Return diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index c88616bb29..12ffe643cc 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,11 @@ +Thu Feb 26 18:25:57 2004 Jonathan Blandford + + * gtk/gtkfilechooser.h (GtkFileChooserAction): Add two more folder + modes to the enum. + + * gtk/gtkfilechooser.c (gtk_file_chooser_set_folder_mode): Remove. + (gtk_file_chooser_get_folder_mode): Remove + Thu Feb 26 17:29:04 2004 Owen Taylor * gdk/x11/gdkevents-x11.c (gdk_wm_protocols_filter): Return diff --git a/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-loader.sgml b/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-loader.sgml index 9e88367406..d15fd4a35f 100644 --- a/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-loader.sgml +++ b/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-loader.sgml @@ -76,6 +76,36 @@ fields. + + + + +@gdkpixbufloader: + + + + + +@gdkpixbufloader: +@arg1: +@arg2: +@arg3: +@arg4: + + + + + +@gdkpixbufloader: + + + + + +@gdkpixbufloader: +@arg1: +@arg2: + @@ -170,33 +200,3 @@ End: --> - - - - -@gdkpixbufloader: - - - - - -@gdkpixbufloader: -@arg1: -@arg2: -@arg3: -@arg4: - - - - - -@gdkpixbufloader: - - - - - -@gdkpixbufloader: -@arg1: -@arg2: - diff --git a/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml b/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml index e0f13c053a..3c67abbc71 100644 --- a/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml +++ b/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml @@ -365,54 +365,6 @@ XlibRGB @obj: A GTK+ object. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - This object describes an individual frame of an animation. diff --git a/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf.sgml b/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf.sgml index 128a9e73ca..639003bdff 100644 --- a/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf.sgml +++ b/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf.sgml @@ -151,6 +151,46 @@ In the future it will do full alpha compositing. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/docs/reference/gtk/tmpl/gtk-unused.sgml b/docs/reference/gtk/tmpl/gtk-unused.sgml index d8ea68b239..6abf77a4db 100644 --- a/docs/reference/gtk/tmpl/gtk-unused.sgml +++ b/docs/reference/gtk/tmpl/gtk-unused.sgml @@ -2094,6 +2094,22 @@ Claim or disclaim ownership of the PRIMARY X selection. @claim: if %TRUE, claim the selection, otherwise, disclaim it. @time: the timestamp for claiming the selection. + + + + + +@chooser: +@Returns: + + + + + + +@chooser: +@folder_mode: + Sets one of the two font filters, to limit the fonts shown. diff --git a/docs/reference/gtk/tmpl/gtkcomboboxentry.sgml b/docs/reference/gtk/tmpl/gtkcomboboxentry.sgml index 273c29a087..1151680ee2 100644 --- a/docs/reference/gtk/tmpl/gtkcomboboxentry.sgml +++ b/docs/reference/gtk/tmpl/gtkcomboboxentry.sgml @@ -46,6 +46,14 @@ a text entry field with a dropdown list @Returns: + + + + + +@Returns: + + diff --git a/docs/reference/gtk/tmpl/gtkfilechooser.sgml b/docs/reference/gtk/tmpl/gtkfilechooser.sgml index 581ef713b6..cc371b1381 100644 --- a/docs/reference/gtk/tmpl/gtkfilechooser.sgml +++ b/docs/reference/gtk/tmpl/gtkfilechooser.sgml @@ -211,11 +211,17 @@ update_preview_cb (GtkFileChooser *file_chooser, gpointer data) existing files or to save to a possibly new file. -@GTK_FILE_CHOOSER_ACTION_OPEN: Indicates Open mode. The file chooser +@GTK_FILE_CHOOSER_ACTION_OPEN: Indicates open mode. The file chooser will only let the user pick an existing file. -@GTK_FILE_CHOOSER_ACTION_SAVE: Indicates Save mode. The file chooser +@GTK_FILE_CHOOSER_ACTION_SAVE: Indicates save mode. The file chooser will let the user pick an existing file, or type in a new filename. +@GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER: Indicates an Open mode for + selecting folders. The file chooser will let the user pick an + existing folder. +@GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER: Indicates a mode for creating a + new folder. The file chooser will let the user name an existing or + new folder. @@ -259,24 +265,6 @@ update_preview_cb (GtkFileChooser *file_chooser, gpointer data) @Returns: - - - - - -@chooser: -@folder_mode: - - - - - - - -@chooser: -@Returns: - - diff --git a/docs/reference/gtk/tmpl/gtkradiobutton.sgml b/docs/reference/gtk/tmpl/gtkradiobutton.sgml index e2bfbc1a15..8d33d0761e 100644 --- a/docs/reference/gtk/tmpl/gtkradiobutton.sgml +++ b/docs/reference/gtk/tmpl/gtkradiobutton.sgml @@ -91,6 +91,13 @@ functions below. + + + + + +@radiobutton: the object which received the signal. + Sets a new group for a radio button. diff --git a/docs/reference/gtk/tmpl/gtkradiomenuitem.sgml b/docs/reference/gtk/tmpl/gtkradiomenuitem.sgml index d028cf386c..0c6e4d057c 100644 --- a/docs/reference/gtk/tmpl/gtkradiomenuitem.sgml +++ b/docs/reference/gtk/tmpl/gtkradiomenuitem.sgml @@ -55,6 +55,13 @@ the interface functions. + + + + + +@radiomenuitem: the object which received the signal. + Creates a new #GtkRadioMenuItem. diff --git a/docs/reference/gtk/tmpl/gtkrc.sgml b/docs/reference/gtk/tmpl/gtkrc.sgml index d83a9b4df8..e5b5f73c96 100644 --- a/docs/reference/gtk/tmpl/gtkrc.sgml +++ b/docs/reference/gtk/tmpl/gtkrc.sgml @@ -721,6 +721,14 @@ Parses resource information directly from a string. @Returns: + + + + + +@settings: + + diff --git a/docs/reference/gtk/tmpl/gtkstyle.sgml b/docs/reference/gtk/tmpl/gtkstyle.sgml index a9958ebd57..09aa87dd9f 100644 --- a/docs/reference/gtk/tmpl/gtkstyle.sgml +++ b/docs/reference/gtk/tmpl/gtkstyle.sgml @@ -52,6 +52,20 @@ Returns whether the style is attached to a window. @white_gc: @bg_pixmap: + + + + + +@style: the object which received the signal. + + + + + + +@style: the object which received the signal. + @@ -884,6 +898,20 @@ Deprecated alias for gtk_style_apply_default_background(). @height: + + + + + +@widget: +@drawable: +@area: +@location: +@is_primary: +@direction: +@draw_arrow: + + diff --git a/gtk/gtkfilechooser.c b/gtk/gtkfilechooser.c index 08c0811dfc..a8ead3f203 100644 --- a/gtk/gtkfilechooser.c +++ b/gtk/gtkfilechooser.c @@ -214,53 +214,6 @@ gtk_file_chooser_get_action (GtkFileChooser *chooser) return action; } -/** - * gtk_file_chooser_set_folder_mode: - * @chooser: a #GtkFileChooser - * @folder_mode: %TRUE if the file chooser is used to select folders - * rather than files. - * - * Sets whether the file chooser is used to select folders - * rather than files. If in folder mode, only folders are displayed - * to the use, and not the individual files inside the folders - * and the user selects a single folder rather than one or - * more files. - * - * Since: 2.4 - **/ -void -gtk_file_chooser_set_folder_mode (GtkFileChooser *chooser, - gboolean folder_mode) -{ - g_return_if_fail (GTK_IS_FILE_CHOOSER (chooser)); - - g_object_set (chooser, "folder-mode", folder_mode, NULL); -} - -/** - * gtk_file_chooser_get_folder_mode: - * @chooser: a #GtkFileChooser - * - * Gets whether the file chooser is used to select folders - * rather than files. See gtk_file_chooser_set_folder_mode() - * - * Return value: %TRUE if the file chooser is used to select - * folders rather than files. - * - * Since: 2.4 - **/ -gboolean -gtk_file_chooser_get_folder_mode (GtkFileChooser *chooser) -{ - gboolean folder_mode; - - g_return_val_if_fail (GTK_IS_FILE_CHOOSER (chooser), FALSE); - - g_object_get (chooser, "folder-mode", &folder_mode, NULL); - - return folder_mode; -} - /** * gtk_file_chooser_set_local_only: * @chooser: a #GtkFileChooser @@ -315,10 +268,10 @@ gtk_file_chooser_get_local_only (GtkFileChooser *chooser) * @chooser: a #GtkFileChooser * @select_multiple: %TRUE if multiple files can be selected. * - * Sets whether multiple files can be selected in the file - * selector. If the file selector if in folder mode (see - * gtk_file_selector_set_folder_mode()) then only one folder - * can be selected, without regard to this setting. + * Sets whether multiple files can be selected in the file selector. This is + * only relevant if the action is set to be GTK_FILE_CHOOSER_ACTION_OPEN or + * GTK_FILE_CHOOSER_ACTION_SAVE. It cannot be set with either of the folder + * actions. * * Since: 2.4 **/ diff --git a/gtk/gtkfilechooser.h b/gtk/gtkfilechooser.h index ec7ecce0d1..a4c733ad8b 100644 --- a/gtk/gtkfilechooser.h +++ b/gtk/gtkfilechooser.h @@ -35,7 +35,9 @@ typedef struct _GtkFileChooser GtkFileChooser; typedef enum { GTK_FILE_CHOOSER_ACTION_OPEN, - GTK_FILE_CHOOSER_ACTION_SAVE + GTK_FILE_CHOOSER_ACTION_SAVE, + GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER, + GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER } GtkFileChooserAction; GType gtk_file_chooser_get_type (void); @@ -56,9 +58,6 @@ GQuark gtk_file_chooser_error_quark (void); void gtk_file_chooser_set_action (GtkFileChooser *chooser, GtkFileChooserAction action); GtkFileChooserAction gtk_file_chooser_get_action (GtkFileChooser *chooser); -void gtk_file_chooser_set_folder_mode (GtkFileChooser *chooser, - gboolean folder_mode); -gboolean gtk_file_chooser_get_folder_mode (GtkFileChooser *chooser); void gtk_file_chooser_set_local_only (GtkFileChooser *chooser, gboolean local_only); gboolean gtk_file_chooser_get_local_only (GtkFileChooser *chooser); diff --git a/gtk/gtkfilechooserdefault.c b/gtk/gtkfilechooserdefault.c index 81181e1cb9..47012301a6 100644 --- a/gtk/gtkfilechooserdefault.c +++ b/gtk/gtkfilechooserdefault.c @@ -142,7 +142,6 @@ struct _GtkFileChooserDefault /* Flags */ - guint folder_mode : 1; guint local_only : 1; guint preview_widget_active : 1; guint select_multiple : 1; @@ -452,7 +451,6 @@ gtk_file_chooser_default_iface_init (GtkFileChooserIface *iface) static void gtk_file_chooser_default_init (GtkFileChooserDefault *impl) { - impl->folder_mode = FALSE; impl->local_only = TRUE; impl->preview_widget_active = TRUE; impl->select_multiple = FALSE; @@ -1112,9 +1110,6 @@ create_folder_tree (GtkFileChooserDefault *impl) GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC); gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (impl->browse_directories_swin), GTK_SHADOW_IN); - if (impl->folder_mode) - gtk_widget_show (impl->browse_directories_swin); - /* Tree */ impl->browse_directories_tree_view = gtk_tree_view_new (); @@ -1255,7 +1250,8 @@ add_bookmark_foreach_cb (GtkTreeModel *model, impl = GTK_FILE_CHOOSER_DEFAULT (data); - if (impl->folder_mode) + if (impl->action == GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER || + impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER) { fs_model = impl->browse_directories_model; child_iter = *iter; @@ -1278,7 +1274,8 @@ add_bookmark_button_clicked_cb (GtkButton *button, GtkWidget *tree_view; GtkTreeSelection *selection; - if (impl->folder_mode) + if (impl->action == GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER || + impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER) tree_view = impl->browse_directories_tree_view; else tree_view = impl->browse_files_tree_view; @@ -1357,8 +1354,6 @@ selection_is_folders (GtkFileChooserDefault *impl) struct is_folders_foreach_closure closure; GtkTreeSelection *selection; - g_assert (!impl->folder_mode); - closure.impl = impl; closure.all_folders = TRUE; @@ -1383,7 +1378,8 @@ bookmarks_check_add_sensitivity (GtkFileChooserDefault *impl) /* Check selection */ - if (impl->folder_mode) + if (impl->action == GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER || + impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER) tree_view = impl->browse_directories_tree_view; else tree_view = impl->browse_files_tree_view; @@ -1393,7 +1389,9 @@ bookmarks_check_add_sensitivity (GtkFileChooserDefault *impl) if (gtk_tree_selection_count_selected_rows (selection) == 0) active = !shortcut_exists (impl, impl->current_folder); else - active = (impl->folder_mode || selection_is_folders (impl)); + active = (impl->action == GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER || + impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER || + selection_is_folders (impl)); gtk_widget_set_sensitive (impl->browse_shortcuts_add_button, active); } @@ -1637,8 +1635,6 @@ create_file_list (GtkFileChooserDefault *impl) GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC); gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (impl->browse_files_swin), GTK_SHADOW_IN); - if (!impl->folder_mode) - gtk_widget_show (impl->browse_files_swin); /* Tree/list view */ @@ -2037,34 +2033,22 @@ update_appearance (GtkFileChooserDefault *impl) { GtkWidget *child; - if (impl->action == GTK_FILE_CHOOSER_ACTION_SAVE) + if (impl->action == GTK_FILE_CHOOSER_ACTION_SAVE || + impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER) { - GtkWidget *top_level; - gtk_widget_show (impl->save_widgets); - top_level = gtk_widget_get_toplevel (GTK_WIDGET (impl)); - if (gtk_expander_get_expanded (GTK_EXPANDER (impl->save_expander))) { gtk_widget_set_sensitive (impl->save_folder_label, FALSE); /*gtk_widget_set_sensitive (impl->save_folder_combo, FALSE);*/ gtk_widget_show (impl->browse_widgets); - if (GTK_IS_WINDOW (top_level)) - gtk_window_set_resizable (GTK_WINDOW (top_level), TRUE); } else { gtk_widget_set_sensitive (impl->save_folder_label, TRUE); /*gtk_widget_set_sensitive (impl->save_folder_combo, TRUE);*/ gtk_widget_hide (impl->browse_widgets); - gtk_widget_queue_resize (top_level); -#if 0 - if (GTK_IS_WINDOW (top_level)) - gtk_window_set_resizable (GTK_WINDOW (top_level), FALSE); - if (GTK_IS_WINDOW (top_level)) - gtk_window_set_resizable (GTK_WINDOW (top_level), TRUE); -#endif } gtk_widget_show (impl->browse_new_folder_button); @@ -2076,24 +2060,23 @@ update_appearance (GtkFileChooserDefault *impl) set_select_multiple (impl, FALSE, TRUE); } } - else /* GTK_FILE_CHOOSER_ACTION_OPEN */ + else if (impl->action == GTK_FILE_CHOOSER_ACTION_OPEN || + impl->action == GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER) { gtk_widget_hide (impl->save_widgets); gtk_widget_show (impl->browse_widgets); - - if (impl->folder_mode) - gtk_widget_show (impl->browse_new_folder_button); - else - gtk_widget_hide (impl->browse_new_folder_button); } - - if (impl->folder_mode) + /* FIXME: */ + if (impl->action == GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER || + impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER) { + gtk_widget_show (impl->browse_new_folder_button); gtk_widget_hide (impl->browse_files_swin); gtk_widget_show (impl->browse_directories_swin); } else { + gtk_widget_hide (impl->browse_new_folder_button); gtk_widget_hide (impl->browse_directories_swin); gtk_widget_show (impl->browse_files_swin); } @@ -2181,16 +2164,6 @@ gtk_file_chooser_default_set_property (GObject *object, case GTK_FILE_CHOOSER_PROP_FILTER: set_current_filter (impl, g_value_get_object (value)); break; - case GTK_FILE_CHOOSER_PROP_FOLDER_MODE: - { - gboolean folder_mode = g_value_get_boolean (value); - if (folder_mode != impl->folder_mode) - { - impl->folder_mode = folder_mode; - update_appearance (impl); - } - } - break; case GTK_FILE_CHOOSER_PROP_LOCAL_ONLY: impl->local_only = g_value_get_boolean (value); break; @@ -2252,9 +2225,6 @@ gtk_file_chooser_default_get_property (GObject *object, case GTK_FILE_CHOOSER_PROP_FILTER: g_value_set_object (value, impl->current_filter); break; - case GTK_FILE_CHOOSER_PROP_FOLDER_MODE: - g_value_set_boolean (value, impl->folder_mode); - break; case GTK_FILE_CHOOSER_PROP_LOCAL_ONLY: g_value_set_boolean (value, impl->local_only); break; @@ -2748,7 +2718,8 @@ get_paths_foreach (GtkTreeModel *model, info = data; - if (info->impl->folder_mode) + if (info->impl->action == GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER || + info->impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER) { fs_model = info->impl->browse_directories_model; sel_iter = *iter; @@ -2805,7 +2776,8 @@ gtk_file_chooser_default_get_paths (GtkFileChooser *chooser) selection = NULL; - if (impl->folder_mode) + if (impl->action == GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER || + impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER) { if (impl->browse_directories_model) selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (impl->browse_directories_tree_view)); @@ -3541,6 +3513,7 @@ list_mtime_data_func (GtkTreeViewColumn *tree_column, if (days_diff > 1 && days_diff < 7) format = "%A"; /* Days from last week */ else + /* FIXME: Get the right format for the locale */ format = _("%d/%b/%Y"); /* Any other date */ if (g_date_strftime (buf, sizeof (buf), format, &mtime) == 0) diff --git a/gtk/gtkfilechooserwidget.c b/gtk/gtkfilechooserwidget.c index c8ca59fc5e..f2a1d75364 100644 --- a/gtk/gtkfilechooserwidget.c +++ b/gtk/gtkfilechooserwidget.c @@ -131,7 +131,6 @@ gtk_file_chooser_widget_constructor (GType type, GtkFileChooserWidgetPrivate *priv; GObject *object; gchar *current_folder; - gchar *current_folder_uri; object = parent_class->constructor (type, n_construct_properties,