vcl/unx/gtk3/gtkinst.cxx | 4 ++++
1 file changed, 4 insertions(+)
New commits:
commit e3068e43679aa4d29e9c28ee056590769e021788
Author: Caolán McNamara <[email protected]>
AuthorDate: Thu Feb 9 20:57:45 2023 +0000
Commit: Caolán McNamara <[email protected]>
CommitDate: Fri Feb 10 17:06:09 2023 +0000
gtk4: occasional crash at exit
Change-Id: I2008d44f5dae0f22e9213f46a740146d6eb85666
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146703
Reviewed-by: Michael Stahl <[email protected]>
Tested-by: Caolán McNamara <[email protected]>
diff --git a/vcl/unx/gtk3/gtkinst.cxx b/vcl/unx/gtk3/gtkinst.cxx
index e369b587b9b4..75b3f418c72e 100644
--- a/vcl/unx/gtk3/gtkinst.cxx
+++ b/vcl/unx/gtk3/gtkinst.cxx
@@ -18570,7 +18570,11 @@ public:
virtual ~GtkInstanceDrawingArea() override
{
+#if GTK_CHECK_VERSION(4,0,0)
+ gtk_widget_remove_controller(m_pMouseEventBox,
GTK_EVENT_CONTROLLER(m_pZoomGesture));
+#else
g_clear_object(&m_pZoomGesture);
+#endif
ImplGetDefaultWindow()->RemoveEventListener(LINK(this,
GtkInstanceDrawingArea, SettingsChangedHdl));