[gtk: 1/2] filechooser: Small fix for select folder mode
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk: 1/2] filechooser: Small fix for select folder mode
- Date: Wed, 27 Apr 2022 13:46:15 +0000 (UTC)
commit 908661fee6a8275b40ef27f813543ef9f7a5aff5
Author: Sophie Herold <sophie hemio de>
Date: Tue Apr 19 00:55:05 2022 +0200
filechooser: Small fix for select folder mode
When changing folders, we were making the select
button insensitive when there is no folder selected.
However, the select button should be usable to
select the current folder.
Fixes #4020
gtk/gtkfilechooserwidget.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/gtk/gtkfilechooserwidget.c b/gtk/gtkfilechooserwidget.c
index b365204d88..be084da421 100644
--- a/gtk/gtkfilechooserwidget.c
+++ b/gtk/gtkfilechooserwidget.c
@@ -2193,7 +2193,9 @@ update_default (GtkFileChooserWidget *impl)
return;
files = gtk_file_chooser_get_files (GTK_FILE_CHOOSER (impl));
- sensitive = (g_list_model_get_n_items (files) > 0 || impl->action == GTK_FILE_CHOOSER_ACTION_SAVE);
+ sensitive = (g_list_model_get_n_items (files) > 0 ||
+ impl->action == GTK_FILE_CHOOSER_ACTION_SAVE ||
+ impl->action == GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER);
gtk_widget_set_sensitive (button, sensitive);
g_object_unref (files);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]