vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx | 4 ++++ 1 file changed, 4 insertions(+)
New commits: commit 678a00dc1eb3ae12ef2d83f6ae12fd6cdf000626 Author: Michael Weghorn <m.wegh...@posteo.de> AuthorDate: Fri Mar 7 14:13:07 2025 +0100 Commit: Michael Weghorn <m.wegh...@posteo.de> CommitDate: Fri Mar 7 18:04:34 2025 +0100 tdf#162995 gtk: Initially hide custom file dialog controls Explicitly set custom file dialog controls to invisible initially, as they are explicitly shown when needed. While this isn't needed for gtk3, where GtkWidget:visible [1] is FALSE by default [1], it is for gtk4, where the property is TRUE by default [2] This addresses the > Currently, too many controls are visible there for gtk4, but that > will be addressed in a separate commit. aspect mentioned in previous commit Change-Id: If351c24010702e374adb816366892d9ed5280d17 Author: Michael Weghorn <m.wegh...@posteo.de> Date: Fri Mar 7 06:10:49 2025 +0100 tdf#162995 gtk4: Show extra controls in file dialog [1] https://docs.gtk.org/gtk3/property.Widget.visible.html [2] https://docs.gtk.org/gtk4/property.Widget.visible.html Change-Id: Ife8bcc97073807b605bee69434a3db60e1967f9e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/182610 Reviewed-by: Michael Weghorn <m.wegh...@posteo.de> Tested-by: Jenkins diff --git a/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx b/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx index c935b3f8488c..18781c5b41ee 100644 --- a/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx +++ b/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx @@ -191,6 +191,7 @@ SalGtkFilePicker::SalGtkFilePicker( const uno::Reference< uno::XComponentContext for( i = 0; i < TOGGLE_LAST; i++ ) { m_pToggles[i] = gtk_check_button_new(); + gtk_widget_set_visible(m_pToggles[i], false); #define LABEL_TOGGLE( elem ) \ case elem : \ @@ -223,10 +224,12 @@ SalGtkFilePicker::SalGtkFilePicker( const uno::Reference< uno::XComponentContext for( i = 0; i < LIST_LAST; i++ ) { m_pHBoxs[i] = gtk_box_new(GTK_ORIENTATION_HORIZONTAL, 0); + gtk_widget_set_visible(m_pHBoxs[i], false); GtkListStore *pListStores[ LIST_LAST ]; pListStores[i] = gtk_list_store_new (1, G_TYPE_STRING); m_pLists[i] = gtk_combo_box_new_with_model(GTK_TREE_MODEL(pListStores[i])); + gtk_widget_set_visible(m_pLists[i], false); g_object_unref (pListStores[i]); // owned by the widget. GtkCellRenderer *pCell = gtk_cell_renderer_text_new (); gtk_cell_layout_pack_start( @@ -235,6 +238,7 @@ SalGtkFilePicker::SalGtkFilePicker( const uno::Reference< uno::XComponentContext GTK_CELL_LAYOUT (m_pLists[i]), pCell, "text", 0, nullptr); m_pListLabels[i] = gtk_label_new( "" ); + gtk_widget_set_visible(m_pListLabels[i], false); #define LABEL_LIST( elem ) \ case elem : \