stack: Use g_object_notify_by_pspec()

https://bugzilla.gnome.org/show_bug.cgi?id=711611
This commit is contained in:
David King 2013-11-05 10:18:37 +00:00 committed by Matthias Clasen
parent 2454522b26
commit 468fd38531

View File

@ -624,7 +624,8 @@ gtk_stack_set_child_property (GtkContainer *container,
gtk_container_child_notify (container, child, "name"); gtk_container_child_notify (container, child, "name");
if (priv->visible_child == info) if (priv->visible_child == info)
g_object_notify (G_OBJECT (stack), "visible-child-name"); g_object_notify_by_pspec (G_OBJECT (stack),
stack_props[PROP_VISIBLE_CHILD_NAME]);
break; break;
@ -955,8 +956,9 @@ set_visible_child (GtkStack *stack,
gtk_widget_queue_resize (GTK_WIDGET (stack)); gtk_widget_queue_resize (GTK_WIDGET (stack));
gtk_widget_queue_draw (GTK_WIDGET (stack)); gtk_widget_queue_draw (GTK_WIDGET (stack));
g_object_notify (G_OBJECT (stack), "visible-child"); g_object_notify_by_pspec (G_OBJECT (stack), stack_props[PROP_VISIBLE_CHILD]);
g_object_notify (G_OBJECT (stack), "visible-child-name"); g_object_notify_by_pspec (G_OBJECT (stack),
stack_props[PROP_VISIBLE_CHILD_NAME]);
gtk_stack_start_transition (stack, transition_type, transition_duration); gtk_stack_start_transition (stack, transition_type, transition_duration);
} }
@ -1149,7 +1151,7 @@ gtk_stack_set_homogeneous (GtkStack *stack,
if (gtk_widget_get_visible (GTK_WIDGET(stack))) if (gtk_widget_get_visible (GTK_WIDGET(stack)))
gtk_widget_queue_resize (GTK_WIDGET (stack)); gtk_widget_queue_resize (GTK_WIDGET (stack));
g_object_notify (G_OBJECT (stack), "homogeneous"); g_object_notify_by_pspec (G_OBJECT (stack), stack_props[PROP_HOMOGENEOUS]);
} }
/** /**
@ -1213,7 +1215,8 @@ gtk_stack_set_transition_duration (GtkStack *stack,
g_return_if_fail (GTK_IS_STACK (stack)); g_return_if_fail (GTK_IS_STACK (stack));
priv->transition_duration = duration; priv->transition_duration = duration;
g_object_notify (G_OBJECT (stack), "transition-duration"); g_object_notify_by_pspec (G_OBJECT (stack),
stack_props[PROP_TRANSITION_DURATION]);
} }
/** /**
@ -1261,7 +1264,8 @@ gtk_stack_set_transition_type (GtkStack *stack,
g_return_if_fail (GTK_IS_STACK (stack)); g_return_if_fail (GTK_IS_STACK (stack));
priv->transition_type = transition; priv->transition_type = transition;
g_object_notify (G_OBJECT (stack), "transition-type"); g_object_notify_by_pspec (G_OBJECT (stack),
stack_props[PROP_TRANSITION_TYPE]);
} }
/** /**