summaryrefslogtreecommitdiff
path: root/gtk/gtkassistant.c
diff options
context:
space:
mode:
Diffstat (limited to 'gtk/gtkassistant.c')
-rw-r--r--gtk/gtkassistant.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/gtk/gtkassistant.c b/gtk/gtkassistant.c
index 0bed0d56e1..c0f72a6ee9 100644
--- a/gtk/gtkassistant.c
+++ b/gtk/gtkassistant.c
@@ -1300,9 +1300,12 @@ gtk_assistant_remove (GtkContainer *container,
{
GtkAssistant *assistant = (GtkAssistant*) container;
- /* Forward this removal to the content notebook. */
- container = (GtkContainer *) assistant->priv->content;
- gtk_container_remove (container, page);
+ /* Forward this removal to the content notebook */
+ if (gtk_widget_get_parent (page) == assistant->priv->content)
+ {
+ container = (GtkContainer *) assistant->priv->content;
+ gtk_container_remove (container, page);
+ }
}
/**
@@ -1668,7 +1671,7 @@ gtk_assistant_remove_page (GtkAssistant *assistant,
page = gtk_assistant_get_nth_page (assistant, page_num);
if (page)
- gtk_assistant_remove (assistant, page);
+ gtk_assistant_remove (GTK_CONTAINER (assistant), page);
}
/**