diff options
Diffstat (limited to 'nx-X11/programs/Xserver/Xi/getprop.c')
-rw-r--r-- | nx-X11/programs/Xserver/Xi/getprop.c | 84 |
1 files changed, 42 insertions, 42 deletions
diff --git a/nx-X11/programs/Xserver/Xi/getprop.c b/nx-X11/programs/Xserver/Xi/getprop.c index 42acf39e8..e8bd19854 100644 --- a/nx-X11/programs/Xserver/Xi/getprop.c +++ b/nx-X11/programs/Xserver/Xi/getprop.c @@ -68,8 +68,8 @@ SOFTWARE. #include "getprop.h" -extern XExtEventInfo EventInfo[]; -extern int ExtEventIndex; +extern XExtEventInfo EventInfo[]; +extern int ExtEventIndex; /*********************************************************************** * @@ -80,13 +80,13 @@ extern int ExtEventIndex; int SProcXGetDeviceDontPropagateList(client) register ClientPtr client; - { +{ REQUEST(xGetDeviceDontPropagateListReq); swaps(&stuff->length); REQUEST_SIZE_MATCH(xGetDeviceDontPropagateListReq); swapl(&stuff->window); - return(ProcXGetDeviceDontPropagateList(client)); - } + return (ProcXGetDeviceDontPropagateList(client)); +} /*********************************************************************** * @@ -97,13 +97,13 @@ SProcXGetDeviceDontPropagateList(client) int ProcXGetDeviceDontPropagateList (client) register ClientPtr client; - { - CARD16 count = 0; - int i; - XEventClass *buf = NULL, *tbuf; - WindowPtr pWin; - xGetDeviceDontPropagateListReply rep; - OtherInputMasks *others; +{ + CARD16 count = 0; + int i; + XEventClass *buf = NULL, *tbuf; + WindowPtr pWin; + xGetDeviceDontPropagateListReply rep; + OtherInputMasks *others; REQUEST(xGetDeviceDontPropagateListReq); REQUEST_SIZE_MATCH(xGetDeviceDontPropagateListReq); @@ -114,44 +114,44 @@ ProcXGetDeviceDontPropagateList (client) rep.length = 0; rep.count = 0; - pWin = (WindowPtr) LookupWindow (stuff->window, client); + pWin = (WindowPtr) LookupWindow(stuff->window, client); if (!pWin) { client->errorValue = stuff->window; - SendErrorToClient(client, IReqCode, X_GetDeviceDontPropagateList, 0, - BadWindow); + SendErrorToClient(client, IReqCode, X_GetDeviceDontPropagateList, 0, + BadWindow); return Success; - } + } if ((others = wOtherInputMasks(pWin)) != 0) { - for (i=0; i<EMASKSIZE; i++) - tbuf = ClassFromMask (NULL, others->dontPropagateMask[i], i, - &count, COUNT); + for (i = 0; i < EMASKSIZE; i++) + tbuf = ClassFromMask(NULL, others->dontPropagateMask[i], i, + &count, COUNT); if (count) { rep.count = count; - buf = (XEventClass *) malloc (rep.count * sizeof(XEventClass)); - rep.length = (rep.count * sizeof (XEventClass) + 3) >> 2; + buf = (XEventClass *) malloc(rep.count * sizeof(XEventClass)); + rep.length = (rep.count * sizeof(XEventClass) + 3) >> 2; tbuf = buf; - for (i=0; i<EMASKSIZE; i++) - tbuf = ClassFromMask (tbuf, others->dontPropagateMask[i], i, - NULL, CREATE); - } + for (i = 0; i < EMASKSIZE; i++) + tbuf = ClassFromMask(tbuf, others->dontPropagateMask[i], i, + NULL, CREATE); } + } WriteReplyToClient (client, sizeof (xGetDeviceDontPropagateListReply), &rep); if (count) { - client->pSwapReplyFunc = (ReplySwapPtr)Swap32Write; - WriteSwappedDataToClient( client, count * sizeof(XEventClass), buf); - free (buf); - } - return Success; + client->pSwapReplyFunc = (ReplySwapPtr) Swap32Write; + WriteSwappedDataToClient(client, count * sizeof(XEventClass), buf); + free(buf); } + return Success; +} /*********************************************************************** * @@ -167,25 +167,25 @@ XEventClass int maskndx; CARD16 *count; int mode; - { - int i,j; - int id = maskndx; - Mask tmask = 0x80000000; +{ + int i, j; + int id = maskndx; + Mask tmask = 0x80000000; - for (i=0; i<32; i++,tmask>>=1) + for (i = 0; i < 32; i++, tmask >>= 1) if (tmask & mask) { - for (j=0; j<ExtEventIndex; j++) + for (j = 0; j < ExtEventIndex; j++) if (EventInfo[j].mask == tmask) { if (mode == COUNT) (*count)++; else - *buf++ = (id << 8) | EventInfo[j].type; - } - } + *buf++ = (id << 8) | EventInfo[j].type; + } + } return (buf); - } +} /*********************************************************************** * @@ -199,9 +199,9 @@ SRepXGetDeviceDontPropagateList (client, size, rep) ClientPtr client; int size; xGetDeviceDontPropagateListReply *rep; - { +{ swaps(&rep->sequenceNumber); swapl(&rep->length); swaps(&rep->count); WriteToClient(client, size, rep); - } +} |