}
E_API Eina_Bool
-e_client_key_send(E_Client *ec, int keycode, Eina_Bool pressed, Evas_Device *dev, unsigned int time)
+e_client_key_send(E_Client *ec, int keycode, Eina_Bool pressed, Ecore_Device *dev, unsigned int time)
{
Eina_Bool res;
}
E_API Eina_Bool
-e_client_key_cancel(E_Client *ec, int keycode, Evas_Device *dev, unsigned int time)
+e_client_key_cancel(E_Client *ec, int keycode, Ecore_Device *dev, unsigned int time)
{
Eina_Bool res;
}
E_API Eina_Bool
-e_client_touch_send(E_Client *ec, int idx, int x, int y, Eina_Bool pressed, Evas_Device *dev, double radius_x, double radius_y, double pressure, double angle, unsigned int time)
+e_client_touch_send(E_Client *ec, int idx, int x, int y, Eina_Bool pressed, Ecore_Device *dev, double radius_x, double radius_y, double pressure, double angle, unsigned int time)
{
Eina_Bool res;
}
E_API Eina_Bool
-e_client_touch_update_send(E_Client *ec, int idx, int x, int y, Evas_Device *dev, double radius_x, double radius_y, double pressure, double angle, unsigned int time)
+e_client_touch_update_send(E_Client *ec, int idx, int x, int y, Ecore_Device *dev, double radius_x, double radius_y, double pressure, double angle, unsigned int time)
{
Eina_Bool res;
}
E_API Eina_Bool
-e_client_mouse_button_send(E_Client *ec, int buttons, Eina_Bool pressed, Evas_Device *dev, unsigned int time)
+e_client_mouse_button_send(E_Client *ec, int buttons, Eina_Bool pressed, Ecore_Device *dev, unsigned int time)
{
Eina_Bool res;
}
E_API Eina_Bool
-e_client_mouse_move_send(E_Client *ec, int x, int y, Evas_Device *dev, unsigned int time)
+e_client_mouse_move_send(E_Client *ec, int x, int y, Ecore_Device *dev, unsigned int time)
{
Eina_Bool res;
}
E_API Eina_Bool
-e_client_mouse_wheel_send(E_Client *ec, int direction, int z, Evas_Device *dev, unsigned int time)
+e_client_mouse_wheel_send(E_Client *ec, int direction, int z, Ecore_Device *dev, unsigned int time)
{
Eina_Bool res;
}
E_API Eina_Bool
-e_client_mouse_in_send(E_Client *ec, int x, int y, Evas_Device *dev, unsigned int time)
+e_client_mouse_in_send(E_Client *ec, int x, int y, Ecore_Device *dev, unsigned int time)
{
Eina_Bool res;
}
E_API Eina_Bool
-e_client_mouse_out_send(E_Client *ec, Evas_Device *dev, unsigned int time)
+e_client_mouse_out_send(E_Client *ec, Ecore_Device *dev, unsigned int time)
{
Eina_Bool res;
E_API E_Pixmap *e_client_pixmap_change(E_Client *ec, E_Pixmap *newcp);
E_API void e_client_window_role_set(E_Client *ec, const char *role);
-E_API Eina_Bool e_client_key_send(E_Client *ec, int keycode, Eina_Bool pressed, Evas_Device *dev, unsigned int time);
-E_API Eina_Bool e_client_key_cancel(E_Client *ec, int keycode, Evas_Device *dev, unsigned int time);
-E_API Eina_Bool e_client_touch_send(E_Client *ec, int idx, int x, int y, Eina_Bool pressed, Evas_Device *dev, double radius_x, double radius_y, double pressure, double angle, unsigned int time);
-E_API Eina_Bool e_client_touch_update_send(E_Client *ec, int idx, int x, int y, Evas_Device *dev, double radius_x, double radius_y, double pressure, double angle, unsigned int time);
+E_API Eina_Bool e_client_key_send(E_Client *ec, int keycode, Eina_Bool pressed, Ecore_Device *dev, unsigned int time);
+E_API Eina_Bool e_client_key_cancel(E_Client *ec, int keycode, Ecore_Device *dev, unsigned int time);
+E_API Eina_Bool e_client_touch_send(E_Client *ec, int idx, int x, int y, Eina_Bool pressed, Ecore_Device *dev, double radius_x, double radius_y, double pressure, double angle, unsigned int time);
+E_API Eina_Bool e_client_touch_update_send(E_Client *ec, int idx, int x, int y, Ecore_Device *dev, double radius_x, double radius_y, double pressure, double angle, unsigned int time);
E_API Eina_Bool e_client_touch_cancel_send(E_Client *ec);
-E_API Eina_Bool e_client_mouse_button_send(E_Client *ec, int buttons, Eina_Bool pressed, Evas_Device *dev, unsigned int time);
-E_API Eina_Bool e_client_mouse_move_send(E_Client *ec, int x, int y, Evas_Device *dev, unsigned int time);
-E_API Eina_Bool e_client_mouse_wheel_send(E_Client *ec, int direction, int z, Evas_Device *dev, unsigned int time);
-E_API Eina_Bool e_client_mouse_in_send(E_Client *ec, int x, int y, Evas_Device *dev, unsigned int time);
-E_API Eina_Bool e_client_mouse_out_send(E_Client *ec, Evas_Device *dev, unsigned int time);
+E_API Eina_Bool e_client_mouse_button_send(E_Client *ec, int buttons, Eina_Bool pressed, Ecore_Device *dev, unsigned int time);
+E_API Eina_Bool e_client_mouse_move_send(E_Client *ec, int x, int y, Ecore_Device *dev, unsigned int time);
+E_API Eina_Bool e_client_mouse_wheel_send(E_Client *ec, int direction, int z, Ecore_Device *dev, unsigned int time);
+E_API Eina_Bool e_client_mouse_in_send(E_Client *ec, int x, int y, Ecore_Device *dev, unsigned int time);
+E_API Eina_Bool e_client_mouse_out_send(E_Client *ec, Ecore_Device *dev, unsigned int time);
E_API Eina_Bool e_client_video_client_has(E_Client *ec);
E_API Eina_Bool e_client_normal_client_has(E_Client *ec);
static void _remote_surface_region_clear(E_Comp_Wl_Remote_Surface *remote_surface);
static void _remote_surface_ignore_output_transform_send(E_Comp_Wl_Remote_Common *common);
-static Evas_Device *
-_device_get_by_identifier(const char *identifier)
+static Ecore_Device *
+_device_get_by_identifier(const char *identifier, Ecore_Device_Class clas)
{
- Evas_Device *dev = NULL;
+ Ecore_Device *dev = NULL;
const Eina_List *devices, *l;
- devices = evas_device_list(e_comp->evas, NULL);
+ devices = ecore_device_list();
EINA_LIST_FOREACH(devices, l, dev)
{
- if (!e_util_strcmp(identifier, evas_device_description_get(dev)))
+ if (clas != ecore_device_class_get(dev)) continue;
+ if (!e_util_strcmp(identifier, ecore_device_identifier_get(dev)))
return dev;
}
return NULL;
}
+static Ecore_Device_Class
+_device_class_convert_to_ecore(uint32_t clas)
+{
+ switch (clas)
+ {
+ case TIZEN_INPUT_DEVICE_CLAS_MOUSE:
+ return ECORE_DEVICE_CLASS_MOUSE;
+ case TIZEN_INPUT_DEVICE_CLAS_TOUCHSCREEN:
+ return ECORE_DEVICE_CLASS_TOUCH;
+ case TIZEN_INPUT_DEVICE_CLAS_KEYBOARD:
+ return ECORE_DEVICE_CLASS_KEYBOARD;
+ default:
+ return ECORE_DEVICE_CLASS_NONE;
+ }
+}
+
static void
_remote_region_mirror_clear(E_Comp_Wl_Remote_Region *region)
{
E_Comp_Wl_Remote_Surface *remote_surface;
E_Client *ec;
- Evas_Device *edev = NULL;
- Evas_Device_Class eclas = EVAS_DEVICE_CLASS_NONE;
+ Ecore_Device *edev = NULL;
+ Ecore_Device_Class eclas = ECORE_DEVICE_CLASS_NONE;
double eradx, erady, epressure, eangle;
remote_surface = wl_resource_get_user_data(resource);
if (e_object_is_del(E_OBJECT(ec))) return;
/* identify class */
- if (clas == TIZEN_INPUT_DEVICE_CLAS_MOUSE)
- eclas = EVAS_DEVICE_CLASS_MOUSE;
- else if (clas == TIZEN_INPUT_DEVICE_CLAS_TOUCHSCREEN)
- eclas = EVAS_DEVICE_CLASS_TOUCH;
- else
+ eclas = _device_class_convert_to_ecore(clas);
+ if (eclas == ECORE_DEVICE_CLASS_NONE)
{
- ERR("Not supported device clas(%d) subclas(%d) identifier(%s)",
+ ERR("Not supported device class(%d) subclass(%d) identifier(%s)",
clas, subclas, identifier);
}
/* find ecore device*/
- edev = _device_get_by_identifier(identifier);
- if (edev)
- {
- eclas = evas_device_class_get(edev);
- }
+ edev = _device_get_by_identifier(identifier, eclas);
/* fixed to */
eradx = wl_fixed_to_double(radius_x);
epressure = wl_fixed_to_double(pressure);
eangle = wl_fixed_to_double(angle);
- if (eclas == EVAS_DEVICE_CLASS_MOUSE)
+ if (eclas == ECORE_DEVICE_CLASS_MOUSE)
{
switch (event_type)
{
break;
}
}
- else if (eclas == EVAS_DEVICE_CLASS_TOUCH)
+ else if (eclas == ECORE_DEVICE_CLASS_TOUCH)
{
switch (event_type)
{
eradx, erady, epressure, eangle,
time);
break;
+ case TIZEN_REMOTE_SURFACE_EVENT_TYPE_MOUSE_IN:
+ e_client_mouse_in_send(ec,
+ x, y,
+ NULL,
+ time);
+ break;
+ case TIZEN_REMOTE_SURFACE_EVENT_TYPE_MOUSE_OUT:
+ e_client_mouse_out_send(ec,
+ NULL,
+ time);
+ break;
default:
ERR("Not supported event_type(%d)", event_type);
break;
E_Comp_Wl_Remote_Surface *remote_surface;
E_Client *ec;
- Evas_Device *edev = NULL;
+ Ecore_Device *edev = NULL;
+ Ecore_Device_Class eclas = ECORE_DEVICE_CLASS_NONE;
remote_surface = wl_resource_get_user_data(resource);
EINA_SAFETY_ON_NULL_RETURN(remote_surface);
if (e_object_is_del(E_OBJECT(ec))) return;
/* identify class */
- edev = _device_get_by_identifier(identifier);
+ eclas = _device_class_convert_to_ecore(clas);
+ if (eclas == ECORE_DEVICE_CLASS_NONE)
+ {
+ ERR("Not supported device class(%d) subclass(%d) identifier(%s)",
+ clas, subclas, identifier);
+ }
+ edev = _device_get_by_identifier(identifier, eclas);
e_client_mouse_wheel_send(ec, direction, z, edev, time);
}
E_Comp_Wl_Remote_Surface *remote_surface;
E_Client *ec;
- Evas_Device *edev = NULL;
- Evas_Device_Class eclas;
+ Ecore_Device *edev = NULL;
+ Ecore_Device_Class eclas = ECORE_DEVICE_CLASS_NONE;
double eradx, erady, epressure, eangle;
remote_surface = wl_resource_get_user_data(resource);
/* identify class */
if (clas == TIZEN_INPUT_DEVICE_CLAS_TOUCHSCREEN)
- eclas = EVAS_DEVICE_CLASS_TOUCH;
+ eclas = ECORE_DEVICE_CLASS_TOUCH;
else
{
ERR("Not supported device clas(%d) subclas(%d identifier(%s)",
return;
}
- /* find ecore device*/
- edev = _device_get_by_identifier(identifier);
- if (edev)
+ /* identify class */
+ eclas = _device_class_convert_to_ecore(clas);
+ if (eclas == ECORE_DEVICE_CLASS_NONE)
{
- eclas = evas_device_class_get(edev);
+ ERR("Not supported device class(%d) subclass(%d) identifier(%s)",
+ clas, subclas, identifier);
}
+ /* find ecore device*/
+ edev = _device_get_by_identifier(identifier, eclas);
+
/* fixed to */
eradx = wl_fixed_to_double(radius_x);
erady = wl_fixed_to_double(radius_y);
epressure = wl_fixed_to_double(pressure);
eangle = wl_fixed_to_double(angle);
- if (eclas == EVAS_DEVICE_CLASS_TOUCH)
+ if (eclas == ECORE_DEVICE_CLASS_TOUCH)
{
switch (event_type)
{
E_Comp_Wl_Remote_Surface *remote_surface;
E_Client *ec;
- Evas_Device *edev = NULL;
- Evas_Device_Class eclas;
+ Ecore_Device *edev = NULL;
+ Ecore_Device_Class eclas = ECORE_DEVICE_CLASS_NONE;
remote_surface = wl_resource_get_user_data(resource);
EINA_SAFETY_ON_NULL_RETURN(remote_surface);
if (e_object_is_del(E_OBJECT(ec))) return;
/* identify class */
- if (clas == TIZEN_INPUT_DEVICE_CLAS_KEYBOARD)
- eclas = EVAS_DEVICE_CLASS_KEYBOARD;
- else
+ eclas = _device_class_convert_to_ecore(clas);
+ if (eclas == ECORE_DEVICE_CLASS_NONE)
{
- ERR("Not supported device class(%d) subclass(%d identifier(%s)",
+ ERR("Not supported device class(%d) subclass(%d) identifier(%s)",
clas, subclas, identifier);
return;
}
/* find ecore device*/
- edev = _device_get_by_identifier(identifier);
- if (edev)
- {
- eclas = evas_device_class_get(edev);
- }
+ edev = _device_get_by_identifier(identifier, eclas);
- if (eclas == EVAS_DEVICE_CLASS_KEYBOARD)
+ if (eclas == ECORE_DEVICE_CLASS_KEYBOARD)
{
switch (event_type)
{