gtk_window_set_attached_to: ref(), not ref_sink() the attach_widget

The attached popup doesn't take ownership of its "parent" widget, so
ref_sink() was wrong, and caused widgets to be leaked.
This commit is contained in:
Michael Natterer 2012-02-21 01:04:53 +01:00
parent db14dc8237
commit 914053a2a3

View File

@ -2662,7 +2662,7 @@ gtk_window_set_attached_to (GtkWindow *window,
{ {
_gtk_widget_add_attached_window (priv->attach_widget, window); _gtk_widget_add_attached_window (priv->attach_widget, window);
g_object_ref_sink (priv->attach_widget); g_object_ref (priv->attach_widget);
} }
/* Update the style, as the widget path might change. */ /* Update the style, as the widget path might change. */