1 /* GTK - The GIMP Toolkit
2  * Copyright (C) 2012, One Laptop Per Child.
3  * Copyright (C) 2014, Red Hat, Inc.
4  *
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Lesser General Public
7  * License as published by the Free Software Foundation; either
8  * version 2 of the License, or (at your option) any later version.
9  *
10  * This library is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13  * Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public
16  * License along with this library. If not, see <http://www.gnu.org/licenses/>.
17  *
18  * Author(s): Carlos Garnacho <carlosg@gnome.org>
19  */
20 
21 #ifndef __GTK_GESTURE_SINGLE_H__
22 #define __GTK_GESTURE_SINGLE_H__
23 
24 #if !defined (__GTK_H_INSIDE__) && !defined (GTK_COMPILATION)
25 #error "Only <gtk/gtk.h> can be included directly."
26 #endif
27 
28 #include <gtk/gtkgesture.h>
29 
30 G_BEGIN_DECLS
31 
32 #define GTK_TYPE_GESTURE_SINGLE         (gtk_gesture_single_get_type ())
33 #define GTK_GESTURE_SINGLE(o)           (G_TYPE_CHECK_INSTANCE_CAST ((o), GTK_TYPE_GESTURE_SINGLE, GtkGestureSingle))
34 #define GTK_GESTURE_SINGLE_CLASS(k)     (G_TYPE_CHECK_CLASS_CAST ((k), GTK_TYPE_GESTURE_SINGLE, GtkGestureSingleClass))
35 #define GTK_IS_GESTURE_SINGLE(o)        (G_TYPE_CHECK_INSTANCE_TYPE ((o), GTK_TYPE_GESTURE_SINGLE))
36 #define GTK_IS_GESTURE_SINGLE_CLASS(k)  (G_TYPE_CHECK_CLASS_TYPE ((k), GTK_TYPE_GESTURE_SINGLE))
37 #define GTK_GESTURE_SINGLE_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), GTK_TYPE_GESTURE_SINGLE, GtkGestureSingleClass))
38 
39 typedef struct _GtkGestureSingle GtkGestureSingle;
40 typedef struct _GtkGestureSingleClass GtkGestureSingleClass;
41 
42 GDK_AVAILABLE_IN_ALL
43 GType       gtk_gesture_single_get_type       (void) G_GNUC_CONST;
44 
45 GDK_AVAILABLE_IN_ALL
46 gboolean    gtk_gesture_single_get_touch_only (GtkGestureSingle *gesture);
47 
48 GDK_AVAILABLE_IN_ALL
49 void        gtk_gesture_single_set_touch_only (GtkGestureSingle *gesture,
50                                                gboolean          touch_only);
51 GDK_AVAILABLE_IN_ALL
52 gboolean    gtk_gesture_single_get_exclusive  (GtkGestureSingle *gesture);
53 
54 GDK_AVAILABLE_IN_ALL
55 void        gtk_gesture_single_set_exclusive  (GtkGestureSingle *gesture,
56                                                gboolean          exclusive);
57 
58 GDK_AVAILABLE_IN_ALL
59 guint       gtk_gesture_single_get_button     (GtkGestureSingle *gesture);
60 
61 GDK_AVAILABLE_IN_ALL
62 void        gtk_gesture_single_set_button     (GtkGestureSingle *gesture,
63                                                guint             button);
64 
65 GDK_AVAILABLE_IN_ALL
66 guint       gtk_gesture_single_get_current_button
67                                               (GtkGestureSingle *gesture);
68 
69 GDK_AVAILABLE_IN_ALL
70 GdkEventSequence * gtk_gesture_single_get_current_sequence
71                                               (GtkGestureSingle *gesture);
72 
73 G_END_DECLS
74 
75 #endif /* __GTK_GESTURE_SINGLE_H__ */
76