diff options
author | Caolán McNamara <caolanm@redhat.com> | 2021-11-15 12:11:55 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2021-11-15 15:42:23 +0100 |
commit | a63dbd76888043bc12ae1b3b6780a10291a34b38 (patch) | |
tree | 3490ede1ae16252ba9332923515c0d233d2ff47b /vcl/unx | |
parent | 829ea811e19fead7ad35049342136b592077674b (diff) |
gtk4: fill in more of the assistant code
Change-Id: Ibcc4eca0abd37c733d60042025c0688a3932002b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125244
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'vcl/unx')
-rw-r--r-- | vcl/unx/gtk3/gtkinst.cxx | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/vcl/unx/gtk3/gtkinst.cxx b/vcl/unx/gtk3/gtkinst.cxx index 27429d2db702..45f3639a2a7f 100644 --- a/vcl/unx/gtk3/gtkinst.cxx +++ b/vcl/unx/gtk3/gtkinst.cxx @@ -7208,11 +7208,17 @@ private: GtkAllocation allocation; int nPageIndex = 0; -#if !GTK_CHECK_VERSION(4, 0, 0) + +#if GTK_CHECK_VERSION(4, 0, 0) + for (GtkWidget* pWidget = gtk_widget_get_first_child(m_pSidebar); + pWidget; pWidget = gtk_widget_get_next_sibling(pChild)) + { +#else GList* pChildren = gtk_container_get_children(GTK_CONTAINER(m_pSidebar)); for (GList* pChild = g_list_first(pChildren); pChild; pChild = g_list_next(pChild)) { GtkWidget* pWidget = static_cast<GtkWidget*>(pChild->data); +#endif if (!gtk_widget_get_visible(pWidget)) continue; @@ -7243,6 +7249,7 @@ private: ++nPageIndex; } +#if !GTK_CHECK_VERSION(4, 0, 0) g_list_free(pChildren); #endif |