material-node: track if node owns reference on parent
authorRobert Bragg <robert@linux.intel.com>
Tue, 26 Oct 2010 16:43:16 +0000 (17:43 +0100)
committerRobert Bragg <robert@linux.intel.com>
Wed, 3 Nov 2010 17:28:45 +0000 (17:28 +0000)
commitbbf27e6b285afca1261eaa448096667415d81219
tree5db9cf2edb7a54d1d50cf916763794b836005d1f
parente5202d6a0da1d94f65ddbe381766d775e1047e26
material-node: track if node owns reference on parent

MaterialNodes are used for the sparse graph of material state and layer
state. In the case of materials there is the idea of weak materials that
don't take a reference on their parent and in that case we need to be
careful not to unref our parent during
_cogl_material_node_unparent_real. This adds a has_parent_reference
member to the CoglMaterialNode struct so we now know when to skip the
unref.
clutter/cogl/cogl/cogl-material-private.h
clutter/cogl/cogl/cogl-material.c