summaryrefslogtreecommitdiff
path: root/src/XSetBMap.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/XSetBMap.c')
-rw-r--r--src/XSetBMap.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/XSetBMap.c b/src/XSetBMap.c
index 716d8c5..bdfe501 100644
--- a/src/XSetBMap.c
+++ b/src/XSetBMap.c
@@ -63,31 +63,31 @@ SOFTWARE.
/* returns either DeviceMappingSuccess or DeviceMappingBusy */
-int
-XSetDeviceButtonMapping (dpy, device, map, nmap)
- register Display *dpy;
- XDevice *device;
- unsigned char map[];
- int nmap;
- {
+int
+XSetDeviceButtonMapping(dpy, device, map, nmap)
+ register Display *dpy;
+ XDevice *device;
+ unsigned char map[];
+ int nmap;
+{
register xSetDeviceButtonMappingReq *req;
xSetDeviceButtonMappingReply rep;
- XExtDisplayInfo *info = XInput_find_display (dpy);
+ XExtDisplayInfo *info = XInput_find_display(dpy);
LockDisplay(dpy);
if (_XiCheckExtInit(dpy, XInput_Initial_Release) == -1)
return (NoSuchExtension);
- GetReq (SetDeviceButtonMapping, req);
+ GetReq(SetDeviceButtonMapping, req);
req->reqType = info->codes->major_opcode;
req->ReqType = X_SetDeviceButtonMapping;
req->map_length = nmap;
- req->length += (nmap + 3)>>2;
+ req->length += (nmap + 3) >> 2;
req->deviceid = device->device_id;
- Data (dpy, (char *)map, (long) nmap); /* note that map is char[] */
- if (_XReply (dpy, (xReply *)&rep, 0, xFalse) == 0) /* suppress error */
+ Data(dpy, (char *)map, (long)nmap); /* note that map is char[] */
+ if (_XReply(dpy, (xReply *) & rep, 0, xFalse) == 0) /* suppress error */
rep.status = MappingSuccess;
UnlockDisplay(dpy);
SyncHandle();
- return ((int) rep.status);
- }
+ return ((int)rep.status);
+}