[gtk+/gtk-3-10] stack: Fix crash on g_object_get("visible-child")



commit 0cbcade19a34550b81542d6c55eab27d8b8dd9ab
Author: Benjamin Otte <otte redhat com>
Date:   Mon Nov 25 02:39:13 2013 +0100

    stack: Fix crash on g_object_get("visible-child")
    
    priv->visible_child is not a GtkWidget but a custom struct holding the
    widget. So use the getter instead.

 gtk/gtkstack.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/gtk/gtkstack.c b/gtk/gtkstack.c
index 0cbc215..65f1f9a 100644
--- a/gtk/gtkstack.c
+++ b/gtk/gtkstack.c
@@ -213,7 +213,7 @@ gtk_stack_get_property (GObject   *object,
       g_value_set_boolean (value, priv->homogeneous);
       break;
     case PROP_VISIBLE_CHILD:
-      g_value_set_object (value, priv->visible_child);
+      g_value_set_object (value, gtk_stack_get_visible_child (stack));
       break;
     case PROP_VISIBLE_CHILD_NAME:
       g_value_set_string (value, gtk_stack_get_visible_child_name (stack));


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]