[mutter] clutter: Remove clutter_container_lower_child



commit d5dd8ebfa959c3e738cd756c1d66de56f8f4d5d8
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date:   Wed Sep 15 22:45:23 2021 -0300

    clutter: Remove clutter_container_lower_child
    
    Also unused.
    
    Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2057>

 clutter/clutter/clutter-container.c            | 80 --------------------------
 clutter/clutter/clutter-container.h            |  5 --
 clutter/clutter/deprecated/clutter-container.h |  5 --
 3 files changed, 90 deletions(-)
---
diff --git a/clutter/clutter/clutter-container.c b/clutter/clutter/clutter-container.c
index 34e809f05e..61e17cd569 100644
--- a/clutter/clutter/clutter-container.c
+++ b/clutter/clutter/clutter-container.c
@@ -129,16 +129,6 @@ container_real_raise (ClutterContainer *container,
   clutter_actor_set_child_above_sibling (self, child, sibling);
 }
 
-static void
-container_real_lower (ClutterContainer *container,
-                      ClutterActor     *child,
-                      ClutterActor     *sibling)
-{
-  ClutterActor *self = CLUTTER_ACTOR (container);
-
-  clutter_actor_set_child_below_sibling (self, child, sibling);
-}
-
 static void
 clutter_container_default_init (ClutterContainerInterface *iface)
 {
@@ -209,7 +199,6 @@ clutter_container_default_init (ClutterContainerInterface *iface)
   iface->add = container_real_add;
   iface->remove = container_real_remove;
   iface->raise = container_real_raise;
-  iface->lower = container_real_lower;
 
   iface->child_meta_type = G_TYPE_INVALID;
   iface->create_child_meta = create_child_meta;
@@ -533,75 +522,6 @@ clutter_container_raise_child (ClutterContainer *container,
   iface->raise (container, actor, sibling);
 }
 
-/**
- * clutter_container_lower_child: (virtual lower)
- * @container: a #ClutterContainer
- * @actor: the actor to raise
- * @sibling: (allow-none): the sibling to lower to, or %NULL to lower
- *   to the bottom
- *
- * Lowers @actor to @sibling level, in the depth ordering.
- *
- * This function calls the #ClutterContainerIface.lower() virtual function,
- * which has been deprecated. The default implementation will call
- * clutter_actor_set_child_below_sibling().
- *
- * Since: 0.6
- *
- * Deprecated: 1.10: Use clutter_actor_set_child_below_sibling() instead.
- */
-void
-clutter_container_lower_child (ClutterContainer *container,
-                               ClutterActor     *actor,
-                               ClutterActor     *sibling)
-{
-  ClutterContainerIface *iface;
-  ClutterActor *self;
-
-  g_return_if_fail (CLUTTER_IS_CONTAINER (container));
-  g_return_if_fail (CLUTTER_IS_ACTOR (actor));
-  g_return_if_fail (sibling == NULL || CLUTTER_IS_ACTOR (sibling));
-
-  if (actor == sibling)
-    return;
-
-  self = CLUTTER_ACTOR (container);
-
-  if (clutter_actor_get_parent (actor) != self)
-    {
-      g_warning ("Actor of type '%s' is not a child of the container "
-                 "of type '%s'",
-                 g_type_name (G_OBJECT_TYPE (actor)),
-                 g_type_name (G_OBJECT_TYPE (container)));
-      return;
-    }
-
-  if (sibling != NULL&&
-      clutter_actor_get_parent (sibling) != self)
-    {
-      g_warning ("Actor of type '%s' is not a child of the container "
-                 "of type '%s'",
-                 g_type_name (G_OBJECT_TYPE (sibling)),
-                 g_type_name (G_OBJECT_TYPE (container)));
-      return;
-    }
-
-  iface = CLUTTER_CONTAINER_GET_IFACE (container);
-
-#ifdef CLUTTER_ENABLE_DEBUG
-  if (G_UNLIKELY (_clutter_diagnostic_enabled ()))
-    {
-      if (iface->lower != container_real_lower)
-        _clutter_diagnostic_message ("The ClutterContainer::lower() "
-                                     "virtual function has been deprecated "
-                                     "and it should not be overridden by "
-                                     "newly written code");
-    }
-#endif /* CLUTTER_ENABLE_DEBUG */
-
-  iface->lower (container, actor, sibling);
-}
-
 /**
  * clutter_container_find_child_by_name:
  * @container: a #ClutterContainer
diff --git a/clutter/clutter/clutter-container.h b/clutter/clutter/clutter-container.h
index 3d13fe75a9..110756930d 100644
--- a/clutter/clutter/clutter-container.h
+++ b/clutter/clutter/clutter-container.h
@@ -61,8 +61,6 @@ typedef struct _ClutterContainerIface   ClutterContainerIface;
  *   virtual function is deprecated, and it should not be overridden.
  * @raise: virtual function for raising a child. This virtual function is
  *   deprecated and it should not be overridden.
- * @lower: virtual function for lowering a child. This virtual function is
- *   deprecated and it should not be overridden.
  * @child_meta_type: The GType used for storing auxiliary information about
  *   each of the containers children.
  * @create_child_meta: virtual function that gets called for each added
@@ -98,9 +96,6 @@ struct _ClutterContainerIface
   void (* raise)            (ClutterContainer *container,
                              ClutterActor     *actor,
                              ClutterActor     *sibling);
-  void (* lower)            (ClutterContainer *container,
-                             ClutterActor     *actor,
-                             ClutterActor     *sibling);
 
   /* ClutterChildMeta management */
   GType                child_meta_type;
diff --git a/clutter/clutter/deprecated/clutter-container.h b/clutter/clutter/deprecated/clutter-container.h
index 81e5f6e641..d4fea41412 100644
--- a/clutter/clutter/deprecated/clutter-container.h
+++ b/clutter/clutter/deprecated/clutter-container.h
@@ -60,11 +60,6 @@ void            clutter_container_raise_child                   (ClutterContaine
                                                                  ClutterActor     *actor,
                                                                  ClutterActor     *sibling);
 
-CLUTTER_DEPRECATED_FOR(clutter_actor_set_child_below_sibling)
-void            clutter_container_lower_child                   (ClutterContainer *container,
-                                                                 ClutterActor     *actor,
-                                                                 ClutterActor     *sibling);
-
 G_END_DECLS
 
 #endif /* __CLUTTER_CONTAINER_DEPRECATED_H__ */


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]