diff --git a/demos/gtk-demo/tree_store.c b/demos/gtk-demo/tree_store.c index 3b383e4..fde0285 100644 --- a/demos/gtk-demo/tree_store.c +++ b/demos/gtk-demo/tree_store.c @@ -149,7 +149,7 @@ static TreeItem R[] = {{"A", A}, {"B", B}, {"C", C}, {NULL}}; static TreeItem O[] = {{"ROOT", R}, {NULL}}; // Artefact added for symmetry -static GListModel *create_node_recursive (GtkTreeStore *model, +static GListStore *create_node_recursive (GtkTreeStore *model, // GListStore* g_list_store_new (GType item_type) TreeItem *current_item, GtkTreeIter *iter_parent, int depth) @@ -173,13 +173,12 @@ static GListModel *create_node_recursive (GtkTreeStore *model, } if (depth == 0) - return G_LIST_MODEL(model); // cast from GtkTreeModel to GListModel or GtkTreeStore + return G_LIST_STORE(model); // can cast to GListModel or to GtkTreeStore ? else return NULL; } - GtkWidget * do_tree_store (GtkWidget *do_widget) { @@ -190,7 +189,7 @@ do_tree_store (GtkWidget *do_widget) GtkWidget *my_tree_box; GtkWidget *my_scrolled_window; GtkWidget *my_tree_view; - GListModel *my_list_model = NULL; + GListStore *my_list_model = NULL; /* create window, etc */ my_window = gtk_window_new ();