update to 1.10.4
[profile/ivi/clutter.git] / clutter / x11 / clutter-device-manager-core-x11.h
1 /*
2  * Clutter.
3  *
4  * An OpenGL based 'interactive canvas' library.
5  *
6  * Copyright © 2009, 2010, 2011  Intel Corp.
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: Emmanuele Bassi <ebassi@linux.intel.com>
22  */
23
24 #ifndef __CLUTTER_DEVICE_MANAGER_X11_H__
25 #define __CLUTTER_DEVICE_MANAGER_X11_H__
26
27 #include <clutter/clutter-device-manager.h>
28
29 G_BEGIN_DECLS
30
31 #define CLUTTER_TYPE_DEVICE_MANAGER_X11            (_clutter_device_manager_x11_get_type ())
32 #define CLUTTER_DEVICE_MANAGER_X11(obj)            (G_TYPE_CHECK_INSTANCE_CAST ((obj), CLUTTER_TYPE_DEVICE_MANAGER_X11, ClutterDeviceManagerX11))
33 #define CLUTTER_IS_DEVICE_MANAGER_X11(obj)         (G_TYPE_CHECK_INSTANCE_TYPE ((obj), CLUTTER_TYPE_DEVICE_MANAGER_X11))
34 #define CLUTTER_DEVICE_MANAGER_X11_CLASS(klass)    (G_TYPE_CHECK_CLASS_CAST ((klass), CLUTTER_TYPE_DEVICE_MANAGER_X11, ClutterDeviceManagerX11Class))
35 #define CLUTTER_IS_DEVICE_MANAGER_X11_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), CLUTTER_TYPE_DEVICE_MANAGER_X11))
36 #define CLUTTER_DEVICE_MANAGER_X11_GET_CLASS(obj)  (G_TYPE_INSTANCE_GET_CLASS ((obj), CLUTTER_TYPE_DEVICE_MANAGER_X11, ClutterDeviceManagerX11Class))
37
38 typedef struct _ClutterDeviceManagerX11         ClutterDeviceManagerX11;
39 typedef struct _ClutterDeviceManagerX11Class    ClutterDeviceManagerX11Class;
40
41 struct _ClutterDeviceManagerX11
42 {
43   ClutterDeviceManager parent_instance;
44
45   GHashTable *devices_by_id;
46
47   /* the list of transient devices */
48   GSList *devices;
49
50   /* the list of all devices, transient and core; this can be
51    * NULL-ified when adding or removing devices
52    */
53   GSList *all_devices;
54
55   ClutterInputDevice *core_pointer;
56   ClutterInputDevice *core_keyboard;
57
58   int xi_event_base;
59 };
60
61 struct _ClutterDeviceManagerX11Class
62 {
63   ClutterDeviceManagerClass parent_class;
64 };
65
66 GType _clutter_device_manager_x11_get_type (void) G_GNUC_CONST;
67
68 G_END_DECLS
69
70 #endif /* __CLUTTER_DEVICE_MANAGER_X11_H__ */