From 9239e8446cf43e82416cbc3fd11d9502daf78ec0 Mon Sep 17 00:00:00 2001 From: Bilal Elmoussaoui Date: Mon, 15 Jul 2024 21:31:42 +0200 Subject: [PATCH] cogl: Remove _real suffix from Node parenting API There is no vfunc to override anymore as it used to only chain-up Part-of: --- cogl/cogl/cogl-node-private.h | 8 ++++---- cogl/cogl/cogl-node.c | 10 +++++----- cogl/cogl/cogl-pipeline-layer.c | 8 ++++---- cogl/cogl/cogl-pipeline.c | 10 +++++----- 4 files changed, 18 insertions(+), 18 deletions(-) diff --git a/cogl/cogl/cogl-node-private.h b/cogl/cogl/cogl-node-private.h index 14e2d9bcb..3f2f7d53e 100644 --- a/cogl/cogl/cogl-node-private.h +++ b/cogl/cogl/cogl-node-private.h @@ -78,12 +78,12 @@ G_DEFINE_AUTOPTR_CLEANUP_FUNC (CoglNode, g_object_unref) GType cogl_node_get_type (void) G_GNUC_CONST; void -_cogl_pipeline_node_set_parent_real (CoglNode *node, - CoglNode *parent, - gboolean take_strong_reference); +_cogl_pipeline_node_set_parent (CoglNode *node, + CoglNode *parent, + gboolean take_strong_reference); void -_cogl_pipeline_node_unparent_real (CoglNode *node); +_cogl_pipeline_node_unparent (CoglNode *node); typedef gboolean (*CoglNodeChildCallback) (CoglNode *child, void *user_data); diff --git a/cogl/cogl/cogl-node.c b/cogl/cogl/cogl-node.c index e20397891..8ca13e79a 100644 --- a/cogl/cogl/cogl-node.c +++ b/cogl/cogl/cogl-node.c @@ -51,9 +51,9 @@ cogl_node_init (CoglNode *node) } void -_cogl_pipeline_node_set_parent_real (CoglNode *node, - CoglNode *parent, - gboolean take_strong_reference) +_cogl_pipeline_node_set_parent (CoglNode *node, + CoglNode *parent, + gboolean take_strong_reference) { /* NB: the old parent may indirectly be keeping the new parent alive * so we have to ref the new parent before unrefing the old. @@ -67,7 +67,7 @@ _cogl_pipeline_node_set_parent_real (CoglNode *node, g_object_ref (parent); if (node->parent) - _cogl_pipeline_node_unparent_real (node); + _cogl_pipeline_node_unparent (node); _cogl_list_insert (&parent->children, &node->link); @@ -83,7 +83,7 @@ _cogl_pipeline_node_set_parent_real (CoglNode *node, } void -_cogl_pipeline_node_unparent_real (CoglNode *node) +_cogl_pipeline_node_unparent (CoglNode *node) { CoglNode *parent = node->parent; diff --git a/cogl/cogl/cogl-pipeline-layer.c b/cogl/cogl/cogl-pipeline-layer.c index 6586ee102..2ed944a01 100644 --- a/cogl/cogl/cogl-pipeline-layer.c +++ b/cogl/cogl/cogl-pipeline-layer.c @@ -54,7 +54,7 @@ cogl_pipeline_layer_dispose (GObject *object) { CoglPipelineLayer *layer = COGL_PIPELINE_LAYER (object); - _cogl_pipeline_node_unparent_real (COGL_NODE (layer)); + _cogl_pipeline_node_unparent (COGL_NODE (layer)); if (layer->differences & COGL_PIPELINE_LAYER_STATE_TEXTURE_DATA && layer->texture != NULL) @@ -469,9 +469,9 @@ _cogl_pipeline_layer_set_parent (CoglPipelineLayer *layer, CoglPipelineLayer *parent) { /* Chain up */ - _cogl_pipeline_node_set_parent_real (COGL_NODE (layer), - COGL_NODE (parent), - TRUE); + _cogl_pipeline_node_set_parent (COGL_NODE (layer), + COGL_NODE (parent), + TRUE); } CoglPipelineLayer * diff --git a/cogl/cogl/cogl-pipeline.c b/cogl/cogl/cogl-pipeline.c index 0b47d46c3..1484a15eb 100644 --- a/cogl/cogl/cogl-pipeline.c +++ b/cogl/cogl/cogl-pipeline.c @@ -98,7 +98,7 @@ destroy_weak_children_cb (CoglNode *node, NULL); pipeline->destroy_callback (pipeline, pipeline->destroy_data); - _cogl_pipeline_node_unparent_real (COGL_NODE (pipeline)); + _cogl_pipeline_node_unparent (COGL_NODE (pipeline)); } return TRUE; @@ -119,7 +119,7 @@ cogl_pipeline_dispose (GObject *object) g_assert (_cogl_list_empty (&COGL_NODE (pipeline)->children)); - _cogl_pipeline_node_unparent_real (COGL_NODE (pipeline)); + _cogl_pipeline_node_unparent (COGL_NODE (pipeline)); if (pipeline->differences & COGL_PIPELINE_STATE_USER_SHADER && pipeline->big_state->user_program) @@ -284,9 +284,9 @@ _cogl_pipeline_set_parent (CoglPipeline *pipeline, gboolean take_strong_reference) { /* Chain up */ - _cogl_pipeline_node_set_parent_real (COGL_NODE (pipeline), - COGL_NODE (parent), - take_strong_reference); + _cogl_pipeline_node_set_parent (COGL_NODE (pipeline), + COGL_NODE (parent), + take_strong_reference); /* Since we just changed the ancestry of the pipeline its cache of * layers could now be invalid so free it... */