ecore-drm: Fix issue of ecore_drm not calling ReleaseDevice when an

input is destroyed

Summary: This fixes an issue where if you VT switch away from a
running Enlightenment and VT switch back, then input would no longer
be working. This was because we never called ReleaseDevice (dbus call)
when we destroyed a device, so any calls to recreate the device would
fail in libinput due to control already being taken.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
This commit is contained in:
Chris Michael 2015-02-17 16:15:52 -05:00
parent 96cbbb3416
commit 6597d39e90
1 changed files with 7 additions and 1 deletions

View File

@ -122,6 +122,9 @@ _device_removed(Ecore_Drm_Input *input EINA_UNUSED, struct libinput_device *devi
/* remove this evdev from the seat's list of devices */
edev->seat->devices = eina_list_remove(edev->seat->devices, edev);
/* tell launcher to release device */
_ecore_drm_launcher_device_close(edev->path, edev->fd);
/* destroy this evdev */
_ecore_drm_evdev_device_destroy(edev);
}
@ -280,7 +283,10 @@ ecore_drm_inputs_destroy(Ecore_Drm_Device *dev)
EINA_LIST_FREE(dev->seats, seat)
{
EINA_LIST_FREE(seat->devices, edev)
_ecore_drm_evdev_device_destroy(edev);
{
_ecore_drm_launcher_device_close(edev->path, edev->fd);
_ecore_drm_evdev_device_destroy(edev);
}
if (seat->name) eina_stringshare_del(seat->name);
free(seat);