mirror of
https://github.com/X11Libre/xserver.git
synced 2026-10-16 00:19:55 +00:00
Input: Add DeleteInputDeviceRequest
Add DIDR, which asks the DDX to remove a device, analogous to NewInputDeviceRequest. Only implemented for XFree86 at the moment.
This commit is contained in:
parent
7b82a836c6
commit
82962bbae2
6 changed files with 43 additions and 1 deletions
|
|
@ -427,6 +427,26 @@ unwind:
|
|||
return rval;
|
||||
}
|
||||
|
||||
void
|
||||
DeleteInputDeviceRequest(DeviceIntPtr pDev)
|
||||
{
|
||||
LocalDevicePtr pInfo = (LocalDevicePtr) pDev->public.devicePrivate;
|
||||
InputDriverPtr drv = pInfo->drv;
|
||||
IDevRec *idev = pInfo->conf_idev;
|
||||
|
||||
RemoveDevice(pDev);
|
||||
|
||||
if(drv->UnInit)
|
||||
drv->UnInit(drv, pInfo, 0);
|
||||
else
|
||||
xf86DeleteInput(pInfo, 0);
|
||||
|
||||
xfree(idev->driver);
|
||||
xfree(idev->identifier);
|
||||
xf86optionListFree(idev->commonOptions);
|
||||
xfree(idev);
|
||||
}
|
||||
|
||||
/*
|
||||
* convenient functions to post events
|
||||
*/
|
||||
|
|
|
|||
Loading…
Reference in a new issue