WIP: Construction itérative de l'arbre. _append() et _set() dans iterate_node() (cleaning)

This commit is contained in:
Jean Sirmai 2023-12-16 13:16:41 +01:00
parent 7278567729
commit d9745c0f6e
Signed by: jean
GPG Key ID: FB3115C340E057E3
1 changed files with 4 additions and 5 deletions

View File

@ -67,13 +67,12 @@ static TreeItem C[] = {{ "H", H }, { NULL }};
static TreeItem B[] = {{ "E", E }, { "F", F }, { "G", G }, { NULL }};
static TreeItem A[] = {{ "C", C }, { "D", D }, { NULL }};
static TreeItem R[] = {{ "A", A }, { "B", B }, { NULL }};
static TreeItem O[] = {{ "R", R }, { NULL }}; // Artefact added for symetry
static TreeItem O[] = {{ "R", R }, { NULL }}; // Artefact added for symmetry
// iterate_node(model, item_0, item_1, &iter, &child_iter);
static void iterate_node(GtkTreeStore *model,
GtkTreeIter *iter_children,
TreeItem *item_children,
GtkTreeIter *iter_parent)
GtkTreeIter *iter_children,
TreeItem *item_children,
GtkTreeIter *iter_parent)
{
gtk_tree_store_append (model, iter_children, iter_parent);
gtk_tree_store_set (model, iter_children, COLUMN_0, item_children->label, -1);