1 /*
2  * Clutter.
3  *
4  * An OpenGL based 'interactive canvas' library.
5  *
6  * Copyright (C) 2010  Intel Corporation.
7  *
8  * This library is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU Lesser General Public
10  * License as published by the Free Software Foundation; either
11  * version 2 of the License, or (at your option) any later version.
12  *
13  * This library is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
16  * Lesser General Public License for more details.
17  *
18  * You should have received a copy of the GNU Lesser General Public
19  * License along with this library. If not, see <http://www.gnu.org/licenses/>.
20  *
21  * Author:
22  *   Emmanuele Bassi <ebassi@linux.intel.com>
23  */
24 
25 #ifndef __CLUTTER_ACTION_H__
26 #define __CLUTTER_ACTION_H__
27 
28 #if !defined(__CLUTTER_H_INSIDE__) && !defined(CLUTTER_COMPILATION)
29 #error "Only <clutter/clutter.h> can be included directly."
30 #endif
31 
32 #include <clutter/clutter-actor-meta.h>
33 
34 G_BEGIN_DECLS
35 
36 #define CLUTTER_TYPE_ACTION (clutter_action_get_type ())
37 
38 CLUTTER_EXPORT
39 G_DECLARE_DERIVABLE_TYPE (ClutterAction, clutter_action,
40                           CLUTTER, ACTION, ClutterActorMeta);
41 
42 /**
43  * ClutterActionClass:
44  *
45  * The ClutterActionClass structure contains only private data
46  *
47  * Since: 1.4
48  */
49 struct _ClutterActionClass
50 {
51   /*< private >*/
52   ClutterActorMetaClass parent_class;
53 
54   void (* _clutter_action1) (void);
55   void (* _clutter_action2) (void);
56   void (* _clutter_action3) (void);
57   void (* _clutter_action4) (void);
58   void (* _clutter_action5) (void);
59   void (* _clutter_action6) (void);
60   void (* _clutter_action7) (void);
61   void (* _clutter_action8) (void);
62 };
63 
64 /* ClutterActor API */
65 CLUTTER_EXPORT
66 void           clutter_actor_add_action            (ClutterActor  *self,
67                                                     ClutterAction *action);
68 CLUTTER_EXPORT
69 void           clutter_actor_add_action_with_name  (ClutterActor  *self,
70                                                     const gchar   *name,
71                                                     ClutterAction *action);
72 CLUTTER_EXPORT
73 void           clutter_actor_remove_action         (ClutterActor  *self,
74                                                     ClutterAction *action);
75 CLUTTER_EXPORT
76 void           clutter_actor_remove_action_by_name (ClutterActor  *self,
77                                                     const gchar   *name);
78 CLUTTER_EXPORT
79 ClutterAction *clutter_actor_get_action            (ClutterActor  *self,
80                                                     const gchar   *name);
81 CLUTTER_EXPORT
82 GList *        clutter_actor_get_actions           (ClutterActor  *self);
83 CLUTTER_EXPORT
84 void           clutter_actor_clear_actions         (ClutterActor  *self);
85 
86 CLUTTER_EXPORT
87 gboolean       clutter_actor_has_actions           (ClutterActor  *self);
88 
89 G_END_DECLS
90 
91 #endif /* __CLUTTER_ACTION_H__ */
92