e_input: add log for completing to remove device 44/302944/1
authorJihoon Kim <jihoon48.kim@samsung.com>
Thu, 14 Dec 2023 10:55:53 +0000 (19:55 +0900)
committerJihoon Kim <jihoon48.kim@samsung.com>
Mon, 18 Dec 2023 02:34:36 +0000 (11:34 +0900)
Change-Id: I8ac8b768df6d7b218385abcf4d72594c8c83ce9a
Signed-off-by: Jihoon Kim <jihoon48.kim@samsung.com>
src/bin/e_input_inputs.c

index 0204005..9abd0a4 100644 (file)
@@ -319,7 +319,7 @@ _e_input_add_ecore_device(E_Input_Evdev *edev, Ecore_Device_Class clas)
 
    _e_input_ecore_device_event(dev, edev->seat ? edev->seat->name : NULL, EINA_TRUE);
 
-   INF("device name(%s), path(%s), class(%s)", e_device_name_get(e_dev), edev->path, _e_input_ecore_device_class_to_string(clas));
+   INF("[Add Device] device name(%s), identifier(%s), class(%s)", e_device_name_get(e_dev), edev->path, _e_input_ecore_device_class_to_string(clas));
 
    return EINA_TRUE;
 }
@@ -334,6 +334,7 @@ _e_input_remove_ecore_device(E_Input_Evdev *edev, Ecore_Device_Class clas)
    Ecore_Device *dev = NULL, *data;
    const char *identifier;
    const gchar *device_identifier;
+   const char *device_remove_log = NULL;
 
    if (!edev->path) return EINA_FALSE;
 
@@ -385,6 +386,11 @@ _e_input_remove_ecore_device(E_Input_Evdev *edev, Ecore_Device_Class clas)
 
         if ((e_device_class_get(device) == clas) && (!strcmp(device_identifier, edev->path)))
           {
+             device_remove_log = eina_stringshare_printf("[Remove Device] device name(%s), identifier(%s), class(%s)",
+                                                         e_device_name_get(device),
+                                                         identifier,
+                                                         _e_input_ecore_device_class_to_string(clas));
+
              if (edev->e_dev)
                {
                   g_object_unref(device);
@@ -402,6 +408,12 @@ _e_input_remove_ecore_device(E_Input_Evdev *edev, Ecore_Device_Class clas)
           }
      }
 
+   if (device_remove_log)
+     {
+        INF("%s", device_remove_log);
+        eina_stringshare_del(device_remove_log);
+     }
+
    return ret;
 }