From 10392359a9ea209cfd08e68231b8e68342f813e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20Dre=C3=9Fler?= Date: Mon, 19 Oct 2020 12:42:56 +0200 Subject: clutter/actor: Make functions to queue relayout/redraw on clones static We don't call those functions from outside ClutterActor and we also shouldn't, so remove them from the private header and define them statically. https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1527 --- clutter/clutter/clutter-actor-private.h | 2 -- clutter/clutter/clutter-actor.c | 60 ++++++++++++++++----------------- 2 files changed, 30 insertions(+), 32 deletions(-) diff --git a/clutter/clutter/clutter-actor-private.h b/clutter/clutter/clutter-actor-private.h index 507558074..545e58299 100644 --- a/clutter/clutter/clutter-actor-private.h +++ b/clutter/clutter/clutter-actor-private.h @@ -257,8 +257,6 @@ void _clutter_actor_attach_clone ClutterActor *clone); void _clutter_actor_detach_clone (ClutterActor *actor, ClutterActor *clone); -void _clutter_actor_queue_redraw_on_clones (ClutterActor *actor); -void _clutter_actor_queue_relayout_on_clones (ClutterActor *actor); void _clutter_actor_queue_only_relayout (ClutterActor *actor); void clutter_actor_clear_stage_views_recursive (ClutterActor *actor); diff --git a/clutter/clutter/clutter-actor.c b/clutter/clutter/clutter-actor.c index 6c1fd7b61..e1ff406b0 100644 --- a/clutter/clutter/clutter-actor.c +++ b/clutter/clutter/clutter-actor.c @@ -2582,6 +2582,21 @@ clutter_actor_real_allocate (ClutterActor *self, g_object_thaw_notify (G_OBJECT (self)); } +static void +_clutter_actor_queue_redraw_on_clones (ClutterActor *self) +{ + ClutterActorPrivate *priv = self->priv; + GHashTableIter iter; + gpointer key; + + if (priv->clones == NULL) + return; + + g_hash_table_iter_init (&iter, priv->clones); + while (g_hash_table_iter_next (&iter, &key, NULL)) + clutter_actor_queue_redraw (key); +} + static void _clutter_actor_propagate_queue_redraw (ClutterActor *self, ClutterActor *origin, @@ -8239,6 +8254,21 @@ clutter_actor_queue_redraw (ClutterActor *self) NULL /* effect */); } +static void +_clutter_actor_queue_relayout_on_clones (ClutterActor *self) +{ + ClutterActorPrivate *priv = self->priv; + GHashTableIter iter; + gpointer key; + + if (priv->clones == NULL) + return; + + g_hash_table_iter_init (&iter, priv->clones); + while (g_hash_table_iter_next (&iter, &key, NULL)) + clutter_actor_queue_relayout (key); +} + void _clutter_actor_queue_only_relayout (ClutterActor *self) { @@ -19212,36 +19242,6 @@ _clutter_actor_detach_clone (ClutterActor *actor, } } -void -_clutter_actor_queue_redraw_on_clones (ClutterActor *self) -{ - ClutterActorPrivate *priv = self->priv; - GHashTableIter iter; - gpointer key; - - if (priv->clones == NULL) - return; - - g_hash_table_iter_init (&iter, priv->clones); - while (g_hash_table_iter_next (&iter, &key, NULL)) - clutter_actor_queue_redraw (key); -} - -void -_clutter_actor_queue_relayout_on_clones (ClutterActor *self) -{ - ClutterActorPrivate *priv = self->priv; - GHashTableIter iter; - gpointer key; - - if (priv->clones == NULL) - return; - - g_hash_table_iter_init (&iter, priv->clones); - while (g_hash_table_iter_next (&iter, &key, NULL)) - clutter_actor_queue_relayout (key); -} - /** * clutter_actor_has_mapped_clones: * @self: a #ClutterActor -- cgit v1.2.1