[gtk+] GtkMenuButton: Don't leak popovers
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] GtkMenuButton: Don't leak popovers
- Date: Thu, 18 Dec 2014 03:57:39 +0000 (UTC)
commit fe82dc5fb294c03c2235be0f3105107e89eafbf5
Author: Matthias Clasen <mclasen redhat com>
Date: Wed Dec 17 22:56:30 2014 -0500
GtkMenuButton: Don't leak popovers
Detach the previous popover from the toplevel when a new one
is set. This should fix
https://bugzilla.gnome.org/show_bug.cgi?id=741652
gtk/gtkmenubutton.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/gtk/gtkmenubutton.c b/gtk/gtkmenubutton.c
index bc0f437..422c07f 100644
--- a/gtk/gtkmenubutton.c
+++ b/gtk/gtkmenubutton.c
@@ -1167,6 +1167,8 @@ gtk_menu_button_set_popover (GtkMenuButton *menu_button,
g_signal_handlers_disconnect_by_func (priv->popover,
menu_deactivate_cb,
menu_button);
+
+ gtk_popover_set_relative_to (GTK_POPOVER (priv->popover), NULL);
}
priv->popover = popover;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]