Release Clutter 1.11.4 (snapshot)
[profile/ivi/clutter.git] / clutter / clutter-swipe-action.h
1 /*
2  * Clutter.
3  *
4  * An OpenGL based 'interactive canvas' library.
5  *
6  * Copyright (C) 2010  Intel Corporation.
7  * Copyright (C) 2011  Robert Bosch Car Multimedia GmbH.
8  *
9  * This library is free software; you can redistribute it and/or
10  * modify it under the terms of the GNU Lesser General Public
11  * License as published by the Free Software Foundation; either
12  * version 2 of the License, or (at your option) any later version.
13  *
14  * This library is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
17  * Lesser General Public License for more details.
18  *
19  * You should have received a copy of the GNU Lesser General Public
20  * License along with this library. If not, see <http://www.gnu.org/licenses/>.
21  *
22  * Author:
23  *   Tomeu Vizoso <tomeu.vizoso@collabora.co.uk>
24  *
25  * Based on ClutterDragAction, written by:
26  *   Emmanuele Bassi <ebassi@linux.intel.com>
27  */
28
29 #if !defined(__CLUTTER_H_INSIDE__) && !defined(CLUTTER_COMPILATION)
30 #error "Only <clutter/clutter.h> can be included directly."
31 #endif
32
33 #ifndef __CLUTTER_SWIPE_ACTION_H__
34 #define __CLUTTER_SWIPE_ACTION_H__
35
36 #include <clutter/clutter-gesture-action.h>
37
38 G_BEGIN_DECLS
39
40 #define CLUTTER_TYPE_SWIPE_ACTION               (clutter_swipe_action_get_type ())
41 #define CLUTTER_SWIPE_ACTION(obj)               (G_TYPE_CHECK_INSTANCE_CAST ((obj), CLUTTER_TYPE_SWIPE_ACTION, ClutterSwipeAction))
42 #define CLUTTER_IS_SWIPE_ACTION(obj)            (G_TYPE_CHECK_INSTANCE_TYPE ((obj), CLUTTER_TYPE_SWIPE_ACTION))
43 #define CLUTTER_SWIPE_ACTION_CLASS(klass)       (G_TYPE_CHECK_CLASS_CAST ((klass), CLUTTER_TYPE_SWIPE_ACTION, ClutterSwipeActionClass))
44 #define CLUTTER_IS_SWIPE_ACTION_CLASS(klass)    (G_TYPE_CHECK_CLASS_TYPE ((klass), CLUTTER_TYPE_SWIPE_ACTION))
45 #define CLUTTER_SWIPE_ACTION_GET_CLASS(obj)     (G_TYPE_INSTANCE_GET_PRIVATE ((obj), CLUTTER_TYPE_SWIPE_ACTION, ClutterSwipeActionClass))
46
47 typedef struct _ClutterSwipeAction              ClutterSwipeAction;
48 typedef struct _ClutterSwipeActionPrivate       ClutterSwipeActionPrivate;
49 typedef struct _ClutterSwipeActionClass         ClutterSwipeActionClass;
50
51 /**
52  * ClutterSwipeAction:
53  *
54  * The <structname>ClutterSwipeAction</structname> structure contains
55  * only private data and should be accessed using the provided API
56  *
57  * Since: 1.8
58  */
59 struct _ClutterSwipeAction
60 {
61   /*< private >*/
62   ClutterGestureAction parent_instance;
63
64   ClutterSwipeActionPrivate *priv;
65 };
66
67 /**
68  * ClutterSwipeActionClass:
69  * @swept: class handler for the #ClutterSwipeAction::swept signal
70  *
71  * The <structname>ClutterSwipeActionClass</structname> structure contains
72  * only private data.
73  *
74  * Since: 1.8
75  */
76 struct _ClutterSwipeActionClass
77 {
78   /*< private >*/
79   ClutterGestureActionClass parent_class;
80
81   /*< public >*/
82   void (* swept)  (ClutterSwipeAction    *action,
83                    ClutterActor          *actor,
84                    ClutterSwipeDirection  direction);
85
86   /*< private >*/
87   void (* _clutter_swipe_action1) (void);
88   void (* _clutter_swipe_action2) (void);
89   void (* _clutter_swipe_action3) (void);
90   void (* _clutter_swipe_action4) (void);
91   void (* _clutter_swipe_action5) (void);
92   void (* _clutter_swipe_action6) (void);
93   void (* _clutter_swipe_action7) (void);
94 };
95
96 GType clutter_swipe_action_get_type (void) G_GNUC_CONST;
97
98 ClutterAction * clutter_swipe_action_new        (void);
99
100 G_END_DECLS
101
102 #endif /* __CLUTTER_SWIPE_ACTION_H__ */