diff options
author | Peter Hutterer <peter@cs.unisa.edu.au> | 2007-11-21 16:06:44 +1030 |
---|---|---|
committer | Peter Hutterer <peter@cs.unisa.edu.au> | 2007-11-21 16:14:49 +1030 |
commit | 33f15689922ad9f1193f803bc1636c82c23ab99e (patch) | |
tree | 63df58cd1093b66fd74e4144608c571450031ba8 /Xext | |
parent | e5dd7a95791748c57cab75c0d8ba9d37f72edccf (diff) |
xtest: switch an inputInfo.pointer over to PickPointer.
Couple of whitespace fixes too.
Diffstat (limited to 'Xext')
-rw-r--r-- | Xext/xtest.c | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/Xext/xtest.c b/Xext/xtest.c index 711b57c09..bd203b193 100644 --- a/Xext/xtest.c +++ b/Xext/xtest.c @@ -124,7 +124,7 @@ ProcXTestGetVersion(client) rep.majorVersion = XTestMajorVersion; rep.minorVersion = XTestMinorVersion; if (client->swapped) { - swaps(&rep.sequenceNumber, n); + swaps(&rep.sequenceNumber, n); swaps(&rep.minorVersion, n); } WriteToClient(client, sizeof(xXTestGetVersionReply), (char *)&rep); @@ -139,7 +139,8 @@ ProcXTestCompareCursor(client) xXTestCompareCursorReply rep; WindowPtr pWin; CursorPtr pCursor; - int n, rc; + int n, rc; + DeviceIntPtr pointer = PickPointer(client); REQUEST_SIZE_MATCH(xXTestCompareCursorReq); rc = dixLookupWindow(&pWin, stuff->window, client, DixUnknownAccess); @@ -148,10 +149,10 @@ ProcXTestCompareCursor(client) if (stuff->cursor == None) pCursor = NullCursor; else if (stuff->cursor == XTestCurrentCursor) - pCursor = GetSpriteCursor(inputInfo.pointer); + pCursor = GetSpriteCursor(pointer); else { pCursor = (CursorPtr)LookupIDByType(stuff->cursor, RT_CURSOR); - if (!pCursor) + if (!pCursor) { client->errorValue = stuff->cursor; return (BadCursor); @@ -162,7 +163,7 @@ ProcXTestCompareCursor(client) rep.sequenceNumber = client->sequence; rep.same = (wCursor(pWin) == pCursor); if (client->swapped) { - swaps(&rep.sequenceNumber, n); + swaps(&rep.sequenceNumber, n); } WriteToClient(client, sizeof(xXTestCompareCursorReply), (char *)&rep); return(client->noClientException); @@ -276,7 +277,7 @@ ProcXTestFakeInput(client) /* swap the request back so we can simply re-execute it */ if (client->swapped) { - (void) XTestSwapFakeInput(client, (xReq *)stuff); + (void) XTestSwapFakeInput(client, (xReq *)stuff); swaps(&stuff->length, n); } ResetCurrentRequest (client); @@ -426,7 +427,7 @@ ProcXTestFakeInput(client) #ifdef PANORAMIX if ((!noPanoramiXExtension - && root->drawable.pScreen->myNum + && root->drawable.pScreen->myNum != XineramaGetCursorScreen(dev)) || (noPanoramiXExtension && root != GetCurrentRootWindow(dev))) @@ -545,14 +546,14 @@ XTestSwapFakeInput(client, req) nev = ((req->length << 2) - sizeof(xReq)) / sizeof(xEvent); for (ev = (xEvent *)&req[1]; --nev >= 0; ev++) { - /* Swap event */ - proc = EventSwapVector[ev->u.u.type & 0177]; + /* Swap event */ + proc = EventSwapVector[ev->u.u.type & 0177]; /* no swapping proc; invalid event type? */ - if (!proc || proc == NotImplemented) { + if (!proc || proc == NotImplemented) { client->errorValue = ev->u.u.type; return BadValue; } - (*proc)(ev, &sev); + (*proc)(ev, &sev); *ev = sev; } return Success; |