- AtspiAccessible *child;
- get_reference_from_iter (&iter_array, &app_name, &path);
- child = ref_accessible (app_name, path);
- accessible->children = g_list_append (accessible->children, child);
+ /* It's the old API with a list of children */
+ /* TODO: Perhaps remove this code eventually */
+ dbus_message_iter_recurse (&iter_struct, &iter_array);
+ while (dbus_message_iter_get_arg_type (&iter_array) != DBUS_TYPE_INVALID)
+ {
+ AtspiAccessible *child;
+ get_reference_from_iter (&iter_array, &app_name, &path);
+ child = ref_accessible (app_name, path);
+ g_ptr_array_remove (accessible->children, child);
+ g_ptr_array_add (accessible->children, child);
+ }
+ children_cached = TRUE;