From 7796022af8b423a429c32e2e1105f3e0287ee165 Mon Sep 17 00:00:00 2001 From: Jeffrey Stedfast Date: Sat, 11 Aug 2001 00:19:08 +0000 Subject: Oops, we didn't need to unref all of the widgets, just a few. 2001-08-10 Jeffrey Stedfast * e-search-bar.c (impl_destroy): Oops, we didn't need to unref all of the widgets, just a few. svn path=/trunk/; revision=11907 --- widgets/misc/e-search-bar.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) (limited to 'widgets/misc/e-search-bar.c') diff --git a/widgets/misc/e-search-bar.c b/widgets/misc/e-search-bar.c index 9461bbecb4..ace1983371 100644 --- a/widgets/misc/e-search-bar.c +++ b/widgets/misc/e-search-bar.c @@ -514,11 +514,7 @@ impl_destroy (GtkObject *object) g_return_if_fail (object != NULL); g_return_if_fail (E_IS_SEARCH_BAR (object)); - - /* Should we really be unrefing all of these widgets? */ - gtk_object_unref (GTK_OBJECT (esb->dropdown)); - gtk_object_unref (GTK_OBJECT (esb->option)); - + /* These two we do need to unref, because we explicitly hold references to them. */ if (esb->entry) @@ -526,18 +522,14 @@ impl_destroy (GtkObject *object) if (esb->suboption) gtk_object_unref (GTK_OBJECT (esb->suboption)); - gtk_object_unref (GTK_OBJECT (esb->dropdown_holder)); - gtk_object_unref (GTK_OBJECT (esb->option_menu)); - gtk_object_unref (GTK_OBJECT (esb->dropdown_menu)); - g_list_foreach (esb->subitem_garbage, (GFunc) free_subitems, NULL); g_list_free (esb->subitem_garbage); - + if (esb->pending_change) { gtk_idle_remove (esb->pending_change); esb->pending_change = 0; } - + if (GTK_OBJECT_CLASS (parent_class)->destroy) GTK_OBJECT_CLASS (parent_class)->destroy (object); } -- cgit v1.2.3