diff --git a/cogl/cogl/cogl-node-private.h b/cogl/cogl/cogl-node-private.h index 6793adc72..9bd97435c 100644 --- a/cogl/cogl/cogl-node-private.h +++ b/cogl/cogl/cogl-node-private.h @@ -67,12 +67,9 @@ struct _CoglNode void _cogl_pipeline_node_init (CoglNode *node); -typedef void (*CoglNodeUnparentVFunc) (CoglNode *node); - void _cogl_pipeline_node_set_parent_real (CoglNode *node, CoglNode *parent, - CoglNodeUnparentVFunc unparent, gboolean take_strong_reference); void diff --git a/cogl/cogl/cogl-node.c b/cogl/cogl/cogl-node.c index e1b3354a0..b02563825 100644 --- a/cogl/cogl/cogl-node.c +++ b/cogl/cogl/cogl-node.c @@ -46,7 +46,6 @@ _cogl_pipeline_node_init (CoglNode *node) void _cogl_pipeline_node_set_parent_real (CoglNode *node, CoglNode *parent, - CoglNodeUnparentVFunc unparent, gboolean take_strong_reference) { /* NB: the old parent may indirectly be keeping the new parent alive @@ -61,7 +60,7 @@ _cogl_pipeline_node_set_parent_real (CoglNode *node, cogl_object_ref (parent); if (node->parent) - unparent (node); + _cogl_pipeline_node_unparent_real (node); _cogl_list_insert (&parent->children, &node->link); diff --git a/cogl/cogl/cogl-pipeline-layer.c b/cogl/cogl/cogl-pipeline-layer.c index 6a4baa769..fd7fa3a2d 100644 --- a/cogl/cogl/cogl-pipeline-layer.c +++ b/cogl/cogl/cogl-pipeline-layer.c @@ -436,13 +436,6 @@ init_layer_state: return layer; } -static void -_cogl_pipeline_layer_unparent (CoglNode *layer) -{ - /* Chain up */ - _cogl_pipeline_node_unparent_real (layer); -} - static void _cogl_pipeline_layer_set_parent (CoglPipelineLayer *layer, CoglPipelineLayer *parent) @@ -450,7 +443,6 @@ _cogl_pipeline_layer_set_parent (CoglPipelineLayer *layer, /* Chain up */ _cogl_pipeline_node_set_parent_real (COGL_NODE (layer), COGL_NODE (parent), - _cogl_pipeline_layer_unparent, TRUE); } @@ -699,7 +691,7 @@ _cogl_pipeline_layer_equal (CoglPipelineLayer *layer0, static void _cogl_pipeline_layer_free (CoglPipelineLayer *layer) { - _cogl_pipeline_layer_unparent (COGL_NODE (layer)); + _cogl_pipeline_node_unparent_real (COGL_NODE (layer)); if (layer->differences & COGL_PIPELINE_LAYER_STATE_TEXTURE_DATA && layer->texture != NULL) diff --git a/cogl/cogl/cogl-pipeline.c b/cogl/cogl/cogl-pipeline.c index f9c7e9bd3..4358c23e9 100644 --- a/cogl/cogl/cogl-pipeline.c +++ b/cogl/cogl/cogl-pipeline.c @@ -148,12 +148,6 @@ _cogl_pipeline_init_default_pipeline (void) ctx->default_pipeline = _cogl_pipeline_object_new (pipeline); } -static void -_cogl_pipeline_unparent (CoglNode *pipeline) -{ - /* Chain up */ - _cogl_pipeline_node_unparent_real (pipeline); -} static gboolean recursively_free_layer_caches_cb (CoglNode *node, @@ -194,7 +188,6 @@ _cogl_pipeline_set_parent (CoglPipeline *pipeline, /* Chain up */ _cogl_pipeline_node_set_parent_real (COGL_NODE (pipeline), COGL_NODE (parent), - _cogl_pipeline_unparent, take_strong_reference); /* Since we just changed the ancestry of the pipeline its cache of @@ -340,7 +333,7 @@ destroy_weak_children_cb (CoglNode *node, NULL); pipeline->destroy_callback (pipeline, pipeline->destroy_data); - _cogl_pipeline_unparent (COGL_NODE (pipeline)); + _cogl_pipeline_node_unparent_real (COGL_NODE (pipeline)); } return TRUE; @@ -359,7 +352,7 @@ _cogl_pipeline_free (CoglPipeline *pipeline) g_assert (_cogl_list_empty (&COGL_NODE (pipeline)->children)); - _cogl_pipeline_unparent (COGL_NODE (pipeline)); + _cogl_pipeline_node_unparent_real (COGL_NODE (pipeline)); if (pipeline->differences & COGL_PIPELINE_STATE_USER_SHADER && pipeline->big_state->user_program)