mirror of
https://github.com/X11Libre/xserver.git
synced 2026-03-24 05:54:08 +00:00
Xi: inline SProcXUngrabDeviceButton()
No need to have a hole bunch of extra functions, if we can just easily inline the few relevant lines. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
committed by
Enrico Weigelt
parent
a28cacbef2
commit
9370aafb36
@@ -386,7 +386,7 @@ SProcIDispatch(ClientPtr client)
|
||||
case X_GrabDeviceButton:
|
||||
return ProcXGrabDeviceButton(client);
|
||||
case X_UngrabDeviceButton:
|
||||
return SProcXUngrabDeviceButton(client);
|
||||
return ProcXUngrabDeviceButton(client);
|
||||
case X_AllowDeviceEvents:
|
||||
return ProcXAllowDeviceEvents(client);
|
||||
case X_GetDeviceFocus:
|
||||
|
||||
@@ -79,7 +79,6 @@ int SProcXIQueryVersion(ClientPtr client);
|
||||
int SProcXISelectEvents(ClientPtr client);
|
||||
int SProcXISetClientPointer(ClientPtr client);
|
||||
int SProcXIWarpPointer(ClientPtr client);
|
||||
int SProcXUngrabDeviceButton(ClientPtr client);
|
||||
int SProcXUngrabDeviceKey(ClientPtr client);
|
||||
|
||||
#endif /* _XSERVER_XI_HANDLERS_H */
|
||||
|
||||
@@ -67,22 +67,6 @@ SOFTWARE.
|
||||
ShiftMask | LockMask | ControlMask | Mod1Mask | Mod2Mask | \
|
||||
Mod3Mask | Mod4Mask | Mod5Mask )
|
||||
|
||||
/***********************************************************************
|
||||
*
|
||||
* Handle requests from a client with a different byte order.
|
||||
*
|
||||
*/
|
||||
|
||||
int _X_COLD
|
||||
SProcXUngrabDeviceButton(ClientPtr client)
|
||||
{
|
||||
REQUEST(xUngrabDeviceButtonReq);
|
||||
REQUEST_SIZE_MATCH(xUngrabDeviceButtonReq);
|
||||
swapl(&stuff->grabWindow);
|
||||
swaps(&stuff->modifiers);
|
||||
return (ProcXUngrabDeviceButton(client));
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
*
|
||||
* Release a grab of a button on an extension device.
|
||||
@@ -92,15 +76,20 @@ SProcXUngrabDeviceButton(ClientPtr client)
|
||||
int
|
||||
ProcXUngrabDeviceButton(ClientPtr client)
|
||||
{
|
||||
REQUEST(xUngrabDeviceButtonReq);
|
||||
REQUEST_SIZE_MATCH(xUngrabDeviceButtonReq);
|
||||
|
||||
if (client->swapped) {
|
||||
swapl(&stuff->grabWindow);
|
||||
swaps(&stuff->modifiers);
|
||||
}
|
||||
|
||||
DeviceIntPtr dev;
|
||||
DeviceIntPtr mdev;
|
||||
WindowPtr pWin;
|
||||
GrabPtr temporaryGrab;
|
||||
int rc;
|
||||
|
||||
REQUEST(xUngrabDeviceButtonReq);
|
||||
REQUEST_SIZE_MATCH(xUngrabDeviceButtonReq);
|
||||
|
||||
rc = dixLookupDevice(&dev, stuff->grabbed_device, client, DixGrabAccess);
|
||||
if (rc != Success)
|
||||
return rc;
|
||||
|
||||
Reference in New Issue
Block a user