summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2014-11-18 13:36:16 +0100
committerMatthias Clasen <mclasen@redhat.com>2014-11-18 13:37:51 +0100
commitcd8576ec1920f73098c33df75d4e037305cc3e11 (patch)
treecc47409d03806efb304b1021134fc64e680987ec
parentd31896bdba9db6883a4ccb120cf73f143a9a98bc (diff)
downloadgtk+-cd8576ec1920f73098c33df75d4e037305cc3e11.tar.gz
GtkStack: Fix an oversight in child renaming
We currently emit a warning if you rename a child to the name it already has. We shouldn't do that.
-rw-r--r--gtk/gtkstack.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/gtk/gtkstack.c b/gtk/gtkstack.c
index 485d8a9cae..130426c582 100644
--- a/gtk/gtkstack.c
+++ b/gtk/gtkstack.c
@@ -650,6 +650,8 @@ gtk_stack_set_child_property (GtkContainer *container,
for (l = priv->children; l != NULL; l = l->next)
{
info2 = l->data;
+ if (info == info2)
+ continue;
if (g_strcmp0 (info2->name, name) == 0)
{
g_warning ("Duplicate child name in GtkStack: %s\n", name);