From ef8ec980260bcd8e9f0819aaa8ea65eb8140ab53 Mon Sep 17 00:00:00 2001 From: jeon Date: Fri, 7 Feb 2020 19:31:47 +0900 Subject: [PATCH] e_input: add touch axis and mouse wheel event logs Change-Id: I3d88302928877cab0f31391b7ada48844141ff2e --- src/bin/e_devicemgr_wl.c | 3 +++ src/bin/e_input_evdev.c | 15 +++++++++++++++ 2 files changed, 18 insertions(+) diff --git a/src/bin/e_devicemgr_wl.c b/src/bin/e_devicemgr_wl.c index 38682a56eb..cf980ff461 100644 --- a/src/bin/e_devicemgr_wl.c +++ b/src/bin/e_devicemgr_wl.c @@ -240,6 +240,9 @@ e_devicemgr_wl_detent_send_event(int detent) { if (wl_resource_get_client(dev_res) != wc) continue; tizen_input_device_send_axis(dev_res, TIZEN_INPUT_DEVICE_AXIS_TYPE_DETENT, f_value); + + DMINF("DETENT : %d => E_Client: %p (pid: %d) (pname: %s)", + detent, ec, ec->netwm.pid, e_client_util_name_get(ec)); } } } diff --git a/src/bin/e_input_evdev.c b/src/bin/e_input_evdev.c index 57e7362939..b2d7b2178f 100644 --- a/src/bin/e_input_evdev.c +++ b/src/bin/e_input_evdev.c @@ -828,6 +828,7 @@ _device_handle_axis(struct libinput_device *device, struct libinput_event_pointe enum libinput_pointer_axis axis; Ecore_Device *ecore_dev = NULL, *detent_data = NULL, *data; Eina_List *l; + E_Comp_Config *comp_conf = NULL; if (!(edev = libinput_device_get_user_data(device))) { @@ -903,6 +904,15 @@ _device_handle_axis(struct libinput_device *device, struct libinput_event_pointe ev->z = libinput_event_pointer_get_axis_value(event, axis); } + comp_conf = e_comp_config_get(); + if (comp_conf && comp_conf->input_log_enable) + { + if (detent_data) + ELOGF("Mouse", "Detent (direction: %d, value: %d)", NULL, ev->direction, ev->z); + else + ELOGF("Mouse", "Wheel (direction: %d, value: %d)", NULL, ev->direction, ev->z); + } + ecore_event_add(ECORE_EVENT_MOUSE_WHEEL, ev, _e_input_event_mouse_wheel_cb_free, NULL); } @@ -1277,6 +1287,7 @@ _device_handle_touch_aux_data(struct libinput_device *device, struct libinput_ev Ecore_Axis *axis; Ecore_Device *ecore_dev = NULL, *data; Eina_List *l; + E_Comp_Config *comp_conf; if (libinput_event_touch_aux_data_get_type(event) != LIBINPUT_TOUCH_AUX_DATA_TYPE_PALM && libinput_event_touch_aux_data_get_value(event) > 0) @@ -1326,6 +1337,10 @@ _device_handle_touch_aux_data(struct libinput_device *device, struct libinput_ev ev->axis = axis; ev->dev = ecore_device_ref(ecore_dev); + comp_conf = e_comp_config_get(); + if (comp_conf && comp_conf->input_log_enable) + ELOGF("Touch", "Axis (label: %d, value: %lf)", NULL, axis->label, axis->value); + ecore_event_add(ECORE_EVENT_AXIS_UPDATE, ev, _e_input_aux_data_event_free, NULL); end: -- 2.34.1