From 3c12b3575d077a87683e0f906cebfbb253f49791 Mon Sep 17 00:00:00 2001 From: Emmanuele Bassi Date: Mon, 27 Feb 2012 15:29:50 +0000 Subject: [PATCH] Add deprecated header for ClutterAnimation --- clutter/Makefile.am | 1 + clutter/clutter-actor.c | 3 +- clutter/clutter-animatable.c | 1 + clutter/clutter-animation.h | 74 ++++++++++---------------- clutter/clutter-deprecated.h | 1 + clutter/clutter-interval.h | 3 +- clutter/clutter-types.h | 1 + clutter/deprecated/clutter-animation.h | 57 ++++++++++++++++++++ 8 files changed, 91 insertions(+), 50 deletions(-) create mode 100644 clutter/deprecated/clutter-animation.h diff --git a/clutter/Makefile.am b/clutter/Makefile.am index 27fde63ec..1781c1b90 100644 --- a/clutter/Makefile.am +++ b/clutter/Makefile.am @@ -233,6 +233,7 @@ source_c_priv = \ deprecated_h = \ $(srcdir)/deprecated/clutter-actor.h \ $(srcdir)/deprecated/clutter-animatable.h \ + $(srcdir)/deprecated/clutter-animation.h \ $(srcdir)/deprecated/clutter-backend.h \ $(srcdir)/deprecated/clutter-behaviour.h \ $(srcdir)/deprecated/clutter-behaviour-depth.h \ diff --git a/clutter/clutter-actor.c b/clutter/clutter-actor.c index 58d09bcf1..ebc1fe29b 100644 --- a/clutter/clutter-actor.c +++ b/clutter/clutter-actor.c @@ -338,9 +338,10 @@ #include "clutter-effect-private.h" #include "clutter-enum-types.h" #include "clutter-fixed-layout.h" +#include "clutter-flatten-effect.h" +#include "clutter-interval.h" #include "clutter-main.h" #include "clutter-marshal.h" -#include "clutter-flatten-effect.h" #include "clutter-paint-volume-private.h" #include "clutter-private.h" #include "clutter-profile.h" diff --git a/clutter/clutter-animatable.c b/clutter/clutter-animatable.c index e6bd38cd2..f4b9a1db2 100644 --- a/clutter/clutter-animatable.c +++ b/clutter/clutter-animatable.c @@ -50,6 +50,7 @@ #endif #include "clutter-animatable.h" +#include "clutter-interval.h" #include "clutter-debug.h" #include "clutter-private.h" diff --git a/clutter/clutter-animation.h b/clutter/clutter-animation.h index d99bd8166..d2811b483 100644 --- a/clutter/clutter-animation.h +++ b/clutter/clutter-animation.h @@ -29,10 +29,6 @@ #ifndef __CLUTTER_ANIMATION_H__ #define __CLUTTER_ANIMATION_H__ -#include -#include -#include -#include #include G_BEGIN_DECLS @@ -135,51 +131,35 @@ ClutterInterval *clutter_animation_get_interval (ClutterAnimation *an const gchar *property_name); void clutter_animation_completed (ClutterAnimation *animation); -CLUTTER_DEPRECATED_IN_1_10_FOR(clutter_animation_set_timeline) -void clutter_animation_set_alpha (ClutterAnimation *animation, - ClutterAlpha *alpha); +/* + * ClutterActor API + */ -CLUTTER_DEPRECATED_IN_1_10_FOR(clutter_animation_get_timeline) -ClutterAlpha * clutter_animation_get_alpha (ClutterAnimation *animation); +ClutterAnimation * clutter_actor_animate (ClutterActor *actor, + gulong mode, + guint duration, + const gchar *first_property_name, + ...) G_GNUC_NULL_TERMINATED; +ClutterAnimation * clutter_actor_animate_with_timeline (ClutterActor *actor, + gulong mode, + ClutterTimeline *timeline, + const gchar *first_property_name, + ...) G_GNUC_NULL_TERMINATED; +ClutterAnimation * clutter_actor_animatev (ClutterActor *actor, + gulong mode, + guint duration, + gint n_properties, + const gchar * const properties[], + const GValue *values); +ClutterAnimation * clutter_actor_animate_with_timelinev (ClutterActor *actor, + gulong mode, + ClutterTimeline *timeline, + gint n_properties, + const gchar * const properties[], + const GValue *values); +ClutterAnimation * clutter_actor_get_animation (ClutterActor *actor); +void clutter_actor_detach_animation (ClutterActor *actor); -ClutterAnimation * clutter_actor_animate (ClutterActor *actor, - gulong mode, - guint duration, - const gchar *first_property_name, - ...) G_GNUC_NULL_TERMINATED; -ClutterAnimation * clutter_actor_animate_with_timeline (ClutterActor *actor, - gulong mode, - ClutterTimeline *timeline, - const gchar *first_property_name, - ...) G_GNUC_NULL_TERMINATED; -ClutterAnimation * clutter_actor_animatev (ClutterActor *actor, - gulong mode, - guint duration, - gint n_properties, - const gchar * const properties[], - const GValue *values); -ClutterAnimation * clutter_actor_animate_with_timelinev (ClutterActor *actor, - gulong mode, - ClutterTimeline *timeline, - gint n_properties, - const gchar * const properties[], - const GValue *values); - -ClutterAnimation * clutter_actor_get_animation (ClutterActor *actor); -void clutter_actor_detach_animation (ClutterActor *actor); - -CLUTTER_DEPRECATED_IN_1_10_FOR(clutter_actor_animate_with_timeline) -ClutterAnimation * clutter_actor_animate_with_alpha (ClutterActor *actor, - ClutterAlpha *alpha, - const gchar *first_property_name, - ...) G_GNUC_NULL_TERMINATED; - -CLUTTER_DEPRECATED_IN_1_10_FOR(clutter_actor_animate_with_timelinev) -ClutterAnimation * clutter_actor_animate_with_alphav (ClutterActor *actor, - ClutterAlpha *alpha, - gint n_properties, - const gchar * const properties[], - const GValue *values); G_END_DECLS #endif /* __CLUTTER_ANIMATION_H__ */ diff --git a/clutter/clutter-deprecated.h b/clutter/clutter-deprecated.h index 6ca93b083..0cd81d0f0 100644 --- a/clutter/clutter-deprecated.h +++ b/clutter/clutter-deprecated.h @@ -5,6 +5,7 @@ #include "deprecated/clutter-actor.h" #include "deprecated/clutter-animatable.h" +#include "deprecated/clutter-animation.h" #include "deprecated/clutter-backend.h" #include "deprecated/clutter-behaviour.h" #include "deprecated/clutter-behaviour-depth.h" diff --git a/clutter/clutter-interval.h b/clutter/clutter-interval.h index dea4733e8..44174f347 100644 --- a/clutter/clutter-interval.h +++ b/clutter/clutter-interval.h @@ -29,7 +29,7 @@ #ifndef __CLUTTER_INTERVAL_H__ #define __CLUTTER_INTERVAL_H__ -#include +#include G_BEGIN_DECLS @@ -40,7 +40,6 @@ G_BEGIN_DECLS #define CLUTTER_IS_INTERVAL_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), CLUTTER_TYPE_INTERVAL)) #define CLUTTER_INTERVAL_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), CLUTTER_TYPE_INTERVAL, ClutterIntervalClass)) -typedef struct _ClutterInterval ClutterInterval; typedef struct _ClutterIntervalPrivate ClutterIntervalPrivate; typedef struct _ClutterIntervalClass ClutterIntervalClass; diff --git a/clutter/clutter-types.h b/clutter/clutter-types.h index 90e9261fb..cb3f2846e 100644 --- a/clutter/clutter-types.h +++ b/clutter/clutter-types.h @@ -57,6 +57,7 @@ typedef struct _ClutterActorIter ClutterActorIter; typedef struct _ClutterAlpha ClutterAlpha; typedef struct _ClutterAnimatable ClutterAnimatable; /* dummy */ typedef struct _ClutterAnimator ClutterAnimator; +typedef struct _ClutterInterval ClutterInterval; typedef struct _ClutterState ClutterState; typedef struct _ClutterTimeline ClutterTimeline; diff --git a/clutter/deprecated/clutter-animation.h b/clutter/deprecated/clutter-animation.h new file mode 100644 index 000000000..50c14bf6f --- /dev/null +++ b/clutter/deprecated/clutter-animation.h @@ -0,0 +1,57 @@ +/* + * Clutter. + * + * An OpenGL based 'interactive canvas' library. + * + * Copyright (C) 2008 Intel Corporation. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library. If not, see . + * + * Author: + * Emmanuele Bassi + */ + +#if !defined(__CLUTTER_H_INSIDE__) && !defined(CLUTTER_COMPILATION) +#error "Only can be included directly." +#endif + +#ifndef __CLUTTER_ANIMATION_DEPRECATED_H__ +#define __CLUTTER_ANIMATION_DEPRECATED_H__ + +#include + +G_BEGIN_DECLS + +CLUTTER_DEPRECATED_IN_1_10_FOR(clutter_animation_set_timeline) +void clutter_animation_set_alpha (ClutterAnimation *animation, + ClutterAlpha *alpha); + +CLUTTER_DEPRECATED_IN_1_10_FOR(clutter_animation_get_timeline) +ClutterAlpha * clutter_animation_get_alpha (ClutterAnimation *animation); + +CLUTTER_DEPRECATED_IN_1_10_FOR(clutter_actor_animate_with_timeline) +ClutterAnimation * clutter_actor_animate_with_alpha (ClutterActor *actor, + ClutterAlpha *alpha, + const gchar *first_property_name, + ...) G_GNUC_NULL_TERMINATED; +CLUTTER_DEPRECATED_IN_1_10_FOR(clutter_actor_animate_with_timelinev) +ClutterAnimation * clutter_actor_animate_with_alphav (ClutterActor *actor, + ClutterAlpha *alpha, + gint n_properties, + const gchar * const properties[], + const GValue *values); + +G_END_DECLS + +#endif /* __CLUTTER_ANIMATION_DEPRECATED_H__ */