remove libds stuffs
[platform/core/uifw/libds-tizen.git] / src / input-devicemgr / input-devicemgr.h
1 #ifndef DS_TIZEN_DEVICEMGR_H
2 #define DS_TIZEN_DEVICEMGR_H
3
4 #include <stdbool.h>
5 #include <linux/uinput.h>
6 #include <wayland-server.h>
7 #include <tizen-extension-server-protocol.h>
8 #include "libds/interfaces/input_device.h"
9 #include <libds/seat.h>
10
11 struct ds_tizen_input_devicemgr_device {
12     char name[UINPUT_MAX_NAME_SIZE + 1];
13     struct ds_input_device *input_device;
14     bool created;
15 };
16
17 struct ds_tizen_input_devicemgr {
18     struct wl_global *global;
19     struct wl_display *display;
20     struct ds_backend *backend;
21     struct ds_seat *seat;
22
23     struct {
24         struct wl_signal destroy;
25     } events;
26
27     struct wl_listener new_input;
28     struct wl_listener backend_destroy;
29     struct wl_listener seat_destroy;
30     struct {
31         struct ds_tizen_input_devicemgr_device *kbd;
32         struct ds_tizen_input_devicemgr_device *ptr;
33         struct ds_tizen_input_devicemgr_device *touch;
34     } devices;
35
36     struct wl_list clients;
37     int ref;
38
39     struct wl_list pressed_keys;
40     struct wl_list keymap_list;
41
42     struct wl_list blocked_keys;
43     struct wl_resource *block_resource;
44     struct wl_event_source *timer;
45     struct ds_seat_keyboard_grab *grab;
46 };
47
48 struct ds_tizen_input_devicemgr_client {
49     struct wl_resource *resource;
50     bool init;
51     struct wl_list link; // ds_tizen_input_devicemgr::clients
52 };
53
54 struct ds_tizen_input_devicemgr_key_info {
55     int keycode;
56     struct wl_list link; // ds_tizen_input_devicemgr::pressed_keys;
57 };
58
59 #endif