Emmanuele Bassi 1520ba6190 actor: Add internal child flag
ClutterActor checks, when destroying and reparenting, if the parent
actor implements the Container interface, and automatically calls the
remove() method to perform a clean removal.

Actors implementing Container, though, might have internal children;
that is, children that are not added through the Container API. It is
already possible to iterate through them using the Container API to
avoid breaking invariants - but calling clutter_actor_destroy() on
these children (even from the Container implementation, and thus outside
of Clutter's control) will either lead to leaks or to segmentation
faults.

Clutter needs a way to distinguish a clutter_actor_set_parent() done on
an internal child from one done on a "public" child; for this reason, a
push/pop pair of functions should be available to Actor implementations
to mark the section where they wish to add internal children:

  ➔ clutter_actor_push_internal ();
    ...
    clutter_actor_set_parent (child1, parent);
    clutter_actor_set_parent (child2, parent);
    ...
  ➔ clutter_actor_pop_internal ();

The set_parent() call will automatically set the newly added
INTERNAL_CHILD private flag on each child, and both
clutter_actor_destroy() and clutter_actor_unparent() will check for the
flag before deciding whether to call the Container's remove method.
2009-12-18 23:33:14 +00:00
..
2009-11-06 11:48:42 +00:00
2009-11-13 17:23:13 +00:00
2009-12-18 23:33:14 +00:00
2009-12-18 23:33:14 +00:00
2009-01-20 18:47:50 +00:00
2009-10-14 11:31:26 +01:00
2009-07-10 11:38:42 +01:00
2009-07-10 11:38:42 +01:00
2009-11-13 15:01:17 +00:00
2009-12-01 14:55:19 +00:00
2009-10-19 12:01:38 +01:00
2009-10-16 15:55:05 +01:00
2009-12-02 16:03:55 +00:00