#include "e_comp_intern.h"
#include "e_comp_wl_intern.h"
#include "e_devicemgr_intern.h"
+#include "e_devicemgr_inputgen_intern.h"
#include "e_pixmap_intern.h"
#include "e_client_intern.h"
#include "e_comp_object_intern.h"
#include "e_devicemgr_intern.h"
+#include "e_devicemgr_inputgen_intern.h"
#include "e_keyrouter_intern.h"
#include "e_input_intern.h"
#include "e_input_event.h"
+#include "e_devicemgr_inputgen_intern.h"
#include "e_devicemgr_intern.h"
#include "e_keyrouter_intern.h"
#include "e_input_evdev_intern.h"
#include <linux/uinput.h>
#include <tizen-extension-server-protocol.h>
+#define INPUTGEN_MAX_BTN 16
+
+typedef struct _E_Devicemgr_Inputgen_Touch_Axis E_Devicemgr_Inputgen_Touch_Axis;
+typedef struct _E_Devicemgr_Inputgen_Client_Data E_Devicemgr_Inputgen_Client_Data;
+typedef struct _E_Devicemgr_Inputgen_Client_Global_Data E_Devicemgr_Inputgen_Client_Global_Data;
+typedef struct _E_Devicemgr_Inputgen_Device_Data E_Devicemgr_Inputgen_Device_Data;
+typedef struct _E_Devicemgr_Inputgen_Resource_Data E_Devicemgr_Inputgen_Resource_Data;
+typedef struct _E_Devicemgr_Coords E_Devicemgr_Coords;
+
+struct _E_Devicemgr_Coords
+{
+ int x, y;
+};
+
+struct _E_Devicemgr_Inputgen_Client_Data
+{
+ struct wl_client *client;
+ int ref;
+};
+
+struct _E_Devicemgr_Inputgen_Client_Global_Data
+{
+ struct wl_client *client;
+ unsigned int clas;
+};
+
+struct _E_Devicemgr_Inputgen_Touch_Axis
+{
+ double radius_x;
+ double radius_y;
+ double pressure;
+ double angle;
+ double palm;
+};
+
+struct _E_Devicemgr_Inputgen_Device_Data
+{
+ int uinp_fd;
+ char *identifier;
+ char name[UINPUT_MAX_NAME_SIZE];
+ Ecore_Device_Class clas;
+ struct
+ {
+ unsigned int pressed;
+ E_Devicemgr_Coords *coords;
+ E_Devicemgr_Inputgen_Touch_Axis *axis;
+ E_Devicemgr_Inputgen_Touch_Axis axis_tmp;
+ } touch;
+ struct
+ {
+ unsigned int pressed;
+ E_Devicemgr_Coords coords;
+ } mouse;
+ struct
+ {
+ Eina_List *pressed;
+ } key;
+
+ Eina_List *clients;
+};
+
+struct _E_Devicemgr_Inputgen_Resource_Data
+{
+ struct wl_resource *resource;
+ char name[UINPUT_MAX_NAME_SIZE];
+ Ecore_Timer *sync_timer;
+};
+
static Ecore_Device_Class
_e_devicemgr_inputgen_class_to_ecore_device_class(unsigned int clas)
{
--- /dev/null
+#ifndef E_DEVICEMGR_INPUTGEN_INTERN_H
+#define E_DEVICEMGR_INPUTGEN_INTERN_H
+
+#include "e_intern.h"
+#include "e_devicemgr.h"
+
+#define INPUT_GENERATOR_DEVICE "Input Generator"
+
+EINTERN int e_devicemgr_create_virtual_device(Ecore_Device_Class clas, const char *name);
+EINTERN void e_devicemgr_destroy_virtual_device(int uinp_fd);
+
+EINTERN int e_devicemgr_inputgen_add(struct wl_client *client, struct wl_resource *resource, uint32_t clas, const char *name);
+EINTERN void e_devicemgr_inputgen_add_with_sync(struct wl_client *client, struct wl_resource *resource, uint32_t clas, const char *name);
+EINTERN void e_devicemgr_inputgen_remove(struct wl_client *client, struct wl_resource *resource, uint32_t clas);
+EINTERN int e_devicemgr_inputgen_generate_key(struct wl_client *client, struct wl_resource *resource, const char *keyname, Eina_Bool pressed);
+EINTERN int e_devicemgr_inputgen_generate_pointer(struct wl_client *client, struct wl_resource *resource, uint32_t type, uint32_t x, uint32_t y, uint32_t button);
+EINTERN int e_devicemgr_inputgen_generate_touch(struct wl_client *client, struct wl_resource *resource, uint32_t type, uint32_t x, uint32_t y, uint32_t finger);
+EINTERN void e_devicemgr_inputgen_get_device_info(E_Devicemgr_Input_Device *dev);
+EINTERN int e_devicemgr_inputgen_generate_wheel(struct wl_client *client, struct wl_resource *resource, uint32_t type, int32_t value);
+EINTERN int e_devicemgr_inputgen_touch_axis_store(struct wl_client *client, struct wl_resource *resource, uint32_t type, double value);
+EINTERN void e_devicemgr_inputgen_device_ready_send(E_Devicemgr_Input_Device *dev);
+
+#endif
#define TRACE_INPUT_DEVICE_END()
#endif
-#define INPUT_GENERATOR_DEVICE "Input Generator"
#define DETENT_DEVICE_NAME "tizen_detent"
-#define INPUTGEN_MAX_BTN 16
typedef struct _E_Devicemgr_Coords E_Devicemgr_Coords;
-typedef struct _E_Devicemgr_Inputgen_Touch_Axis E_Devicemgr_Inputgen_Touch_Axis;
-typedef struct _E_Devicemgr_Inputgen_Client_Data E_Devicemgr_Inputgen_Client_Data;
-typedef struct _E_Devicemgr_Inputgen_Client_Global_Data E_Devicemgr_Inputgen_Client_Global_Data;
-typedef struct _E_Devicemgr_Inputgen_Device_Data E_Devicemgr_Inputgen_Device_Data;
-typedef struct _E_Devicemgr_Inputgen_Resource_Data E_Devicemgr_Inputgen_Resource_Data;
struct _E_Devicemgr_Coords
{
int x, y;
};
-struct _E_Devicemgr_Inputgen_Client_Data
-{
- struct wl_client *client;
- int ref;
-};
-
-struct _E_Devicemgr_Inputgen_Client_Global_Data
-{
- struct wl_client *client;
- unsigned int clas;
-};
-
-struct _E_Devicemgr_Inputgen_Touch_Axis
-{
- double radius_x;
- double radius_y;
- double pressure;
- double angle;
- double palm;
-};
-
-struct _E_Devicemgr_Inputgen_Device_Data
-{
- int uinp_fd;
- char *identifier;
- char name[UINPUT_MAX_NAME_SIZE];
- Ecore_Device_Class clas;
- struct
- {
- unsigned int pressed;
- E_Devicemgr_Coords *coords;
- E_Devicemgr_Inputgen_Touch_Axis *axis;
- E_Devicemgr_Inputgen_Touch_Axis axis_tmp;
- } touch;
- struct
- {
- unsigned int pressed;
- E_Devicemgr_Coords coords;
- } mouse;
- struct
- {
- Eina_List *pressed;
- } key;
-
- Eina_List *clients;
-};
-
-struct _E_Devicemgr_Inputgen_Resource_Data
-{
- struct wl_resource *resource;
- char name[UINPUT_MAX_NAME_SIZE];
- Ecore_Timer *sync_timer;
-};
-
struct _E_Devicemgr_Conf_Edd
{
struct
EINTERN void e_devicemgr_conf_init(E_Devicemgr_Config_Data *dconfig);
EINTERN void e_devicemgr_conf_fini(E_Devicemgr_Config_Data *dconfig);
-EINTERN int e_devicemgr_inputgen_add(struct wl_client *client, struct wl_resource *resource, uint32_t clas, const char *name);
-EINTERN void e_devicemgr_inputgen_add_with_sync(struct wl_client *client, struct wl_resource *resource, uint32_t clas, const char *name);
-EINTERN void e_devicemgr_inputgen_remove(struct wl_client *client, struct wl_resource *resource, uint32_t clas);
-EINTERN int e_devicemgr_inputgen_generate_key(struct wl_client *client, struct wl_resource *resource, const char *keyname, Eina_Bool pressed);
-EINTERN int e_devicemgr_inputgen_generate_pointer(struct wl_client *client, struct wl_resource *resource, uint32_t type, uint32_t x, uint32_t y, uint32_t button);
-EINTERN int e_devicemgr_inputgen_generate_touch(struct wl_client *client, struct wl_resource *resource, uint32_t type, uint32_t x, uint32_t y, uint32_t finger);
-EINTERN void e_devicemgr_inputgen_get_device_info(E_Devicemgr_Input_Device *dev);
-EINTERN int e_devicemgr_inputgen_generate_wheel(struct wl_client *client, struct wl_resource *resource, uint32_t type, int32_t value);
-EINTERN int e_devicemgr_inputgen_touch_axis_store(struct wl_client *client, struct wl_resource *resource, uint32_t type, double value);
-EINTERN void e_devicemgr_inputgen_device_ready_send(E_Devicemgr_Input_Device *dev);
-
EINTERN int e_devicemgr_create_virtual_device(Ecore_Device_Class clas, const char *name);
EINTERN void e_devicemgr_destroy_virtual_device(int uinp_fd);
#include "e_devicemgr_wl_intern.h"
#include "e_devicemgr_intern.h"
#include "e_devicemgr_block_intern.h"
+#include "e_devicemgr_inputgen_intern.h"
#include "e_input_intern.h"
#include "e_comp_wl_intern.h"
#include "e_comp_wl_input_intern.h"