[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.4' - vcl/unx
Caolán McNamara (via logerrit)
logerrit at kemper.freedesktop.org
Fri Aug 28 23:04:11 UTC 2020
vcl/unx/gtk3/gtk3gtkinst.cxx | 16 +++++++++++++++-
1 file changed, 15 insertions(+), 1 deletion(-)
New commits:
commit d9fc5fa077212a09aebe373eb478405be4a5c3bd
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Thu Dec 19 10:50:40 2019 +0000
Commit: Aron Budea <aron.budea at collabora.com>
CommitDate: Sat Aug 29 01:03:34 2020 +0200
Resolves: tdf#129484 install decimal key handler for all widgets again
reparent notebook back to its original parent so its not destroyed
when the overflow parent is destroyed
and
add g_object_ref/g_object_unref guard to GtkInstanceWidget
Change-Id: I85d691c05e82531e398736258668e024c4aa1e64
Reviewed-on: https://gerrit.libreoffice.org/85508
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
(cherry picked from commit 2a5d4ed38df988077bcec62da331a7958ce0aaf3)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101587
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
Reviewed-by: Pranam Lashkari <lpranam at collabora.com>
diff --git a/vcl/unx/gtk3/gtk3gtkinst.cxx b/vcl/unx/gtk3/gtk3gtkinst.cxx
index fe87b9764dcd..8f50dcb7b260 100644
--- a/vcl/unx/gtk3/gtk3gtkinst.cxx
+++ b/vcl/unx/gtk3/gtk3gtkinst.cxx
@@ -2175,6 +2175,10 @@ public:
, m_nDragDropReceivedSignalId(0)
, m_nDragLeaveSignalId(0)
{
+ if (!bTakeOwnership)
+ g_object_ref(m_pWidget);
+
+ localizeDecimalSeparator();
}
virtual void connect_key_press(const Link<const KeyEvent&, bool>& rLink) override
@@ -2737,6 +2741,8 @@ public:
if (m_bTakeOwnership)
gtk_widget_destroy(m_pWidget);
+ else
+ g_object_unref(m_pWidget);
}
virtual void disable_notify_events()
@@ -6027,7 +6033,16 @@ public:
g_signal_handler_disconnect(m_pOverFlowNotebook, m_nOverFlowSwitchPageSignalId);
gtk_widget_destroy(GTK_WIDGET(m_pOverFlowNotebook));
if (m_pOverFlowBox)
+ {
+ // put it back to how we found it initially
+ GtkWidget* pParent = gtk_widget_get_parent(GTK_WIDGET(m_pOverFlowBox));
+ g_object_ref(m_pNotebook);
+ gtk_container_remove(GTK_CONTAINER(m_pOverFlowBox), GTK_WIDGET(m_pNotebook));
+ gtk_container_add(GTK_CONTAINER(pParent), GTK_WIDGET(m_pNotebook));
+ g_object_unref(m_pNotebook);
+
gtk_widget_destroy(GTK_WIDGET(m_pOverFlowBox));
+ }
}
};
@@ -10356,7 +10371,6 @@ public:
, m_bBlockOutput(false)
, m_bBlank(false)
{
- localizeDecimalSeparator();
}
virtual int get_value() const override
More information about the Libreoffice-commits
mailing list