[Libreoffice-commits] core.git: vcl/unx

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Fri Jul 9 07:57:55 UTC 2021


 vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx |    2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 4c24250cd52ab36ae0a44459675752ec22530f42
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Thu Jul 8 16:15:59 2021 +0100
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Fri Jul 9 09:57:13 2021 +0200

    gtk4: use gtk_widget_get_preferred_size instead of gtk_widget_size_request
    
    Change-Id: I0d739b88095a5ab7a66d5bfb93f75366427628e5
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118654
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx b/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx
index 14f7762fd7b0..c6f1b72c9c0b 100644
--- a/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx
+++ b/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx
@@ -1139,6 +1139,8 @@ static void HackWidthToFirst(GtkComboBox *pWidget)
     GtkRequisition requisition;
 #if !GTK_CHECK_VERSION(4, 0, 0)
     gtk_widget_size_request(GTK_WIDGET(pWidget), &requisition);
+#else
+    gtk_widget_get_preferred_size(GTK_WIDGET(pWidget), &requisition, nullptr);
 #endif
     gtk_widget_set_size_request(GTK_WIDGET(pWidget), requisition.width, -1);
 }


More information about the Libreoffice-commits mailing list