summaryrefslogtreecommitdiff
path: root/gtk/gtknotebook.c
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2020-05-09 10:33:02 -0400
committerMatthias Clasen <mclasen@redhat.com>2020-05-11 12:20:59 -0400
commit025375ff5f244bbf22b9bd932148dfefc3dce82d (patch)
tree0516525f4463778f4c7577d63da6cda2af64486c /gtk/gtknotebook.c
parentcd0081d08ab9abccc3bddc8b597413d17f2af709 (diff)
downloadgtk+-025375ff5f244bbf22b9bd932148dfefc3dce82d.tar.gz
Replace gtk_widget_destroy everywhere
Replace all remaining uses of gtk_widget_destroy by gtk_container_remove or g_object_unref.
Diffstat (limited to 'gtk/gtknotebook.c')
-rw-r--r--gtk/gtknotebook.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/gtk/gtknotebook.c b/gtk/gtknotebook.c
index 0b9ba6e6f2..eb5ac27d7d 100644
--- a/gtk/gtknotebook.c
+++ b/gtk/gtknotebook.c
@@ -4229,7 +4229,7 @@ gtk_notebook_real_remove (GtkNotebook *notebook,
g_object_ref (tab_label);
gtk_notebook_remove_tab_label (notebook, page);
if (destroying)
- gtk_widget_destroy (tab_label);
+ gtk_widget_unparent (tab_label);
g_object_unref (tab_label);
}
@@ -6100,7 +6100,7 @@ gtk_notebook_set_show_tabs (GtkNotebook *notebook,
children = children->next;
if (page->default_tab)
{
- gtk_widget_destroy (page->tab_label);
+ gtk_widget_unparent (page->tab_label);
page->tab_label = NULL;
}
else
@@ -6391,7 +6391,7 @@ gtk_notebook_popup_disable (GtkNotebook *notebook)
gtk_container_foreach (GTK_CONTAINER (notebook->menu_box),
(GtkCallback) gtk_notebook_menu_label_unparent, NULL);
- gtk_widget_destroy (notebook->menu);
+
notebook->menu = NULL;
notebook->menu_box = NULL;