diff options
-rw-r--r-- | Xi/Makefile.am | 2 | ||||
-rw-r--r-- | Xi/extgrbdev.c | 100 | ||||
-rw-r--r-- | Xi/extgrbdev.h | 43 | ||||
-rw-r--r-- | Xi/extinit.c | 9 |
4 files changed, 2 insertions, 152 deletions
diff --git a/Xi/Makefile.am b/Xi/Makefile.am index 09dd41d0e..7fd593c87 100644 --- a/Xi/Makefile.am +++ b/Xi/Makefile.am @@ -27,8 +27,6 @@ libXi_la_SOURCES = \ devbell.h \ exevents.c \ exglobals.h \ - extgrbdev.c \ - extgrbdev.h \ extinit.c \ getbmap.c \ getbmap.h \ diff --git a/Xi/extgrbdev.c b/Xi/extgrbdev.c deleted file mode 100644 index da4e618c2..000000000 --- a/Xi/extgrbdev.c +++ /dev/null @@ -1,100 +0,0 @@ -/* - * Copyright 2007-2008 Peter Hutterer - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the "Software"), - * to deal in the Software without restriction, including without limitation - * the rights to use, copy, modify, merge, publish, distribute, sublicense, - * and/or sell copies of the Software, and to permit persons to whom the - * Software is furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice (including the next - * paragraph) shall be included in all copies or substantial portions of the - * Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL - * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING - * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER - * DEALINGS IN THE SOFTWARE. - * - * Author: Peter Hutterer, University of South Australia, NICTA - */ - -/*********************************************************************** - * - * Request to fake data for a given device. - * - */ - -#ifdef HAVE_DIX_CONFIG_H -#include <dix-config.h> -#endif - -#include <X11/X.h> /* for inputstr.h */ -#include <X11/Xproto.h> /* Request macro */ -#include "inputstr.h" /* DeviceIntPtr */ -#include "windowstr.h" /* window structure */ -#include "scrnintstr.h" /* screen structure */ -#include <X11/extensions/XI.h> -#include <X11/extensions/XIproto.h> -#include <X11/extensions/Xge.h> -#include "extnsionst.h" -#include "exevents.h" -#include "exglobals.h" - -#include "grabdev.h" /* CreateMaskFromList */ - -#include "extgrbdev.h" - -int -SProcXExtendedGrabDevice(ClientPtr client) -{ - char n; - int i; - long* p; - - REQUEST(xExtendedGrabDeviceReq); - swaps(&stuff->length, n); - REQUEST_AT_LEAST_SIZE(xExtendedGrabDeviceReq); - - swapl(&stuff->grab_window, n); - swapl(&stuff->time, n); - swapl(&stuff->confine_to, n); - swapl(&stuff->cursor, n); - swaps(&stuff->event_count, n); - swaps(&stuff->generic_event_count, n); - - p = (long *)&stuff[1]; - for (i = 0; i < stuff->event_count; i++) { - swapl(p, n); - p++; - } - - for (i = 0; i < stuff->generic_event_count; i++) { - p++; /* first 4 bytes are extension type and padding */ - swapl(p, n); - p++; - } - - return ProcXExtendedGrabDevice(client); -} - - -int -ProcXExtendedGrabDevice(ClientPtr client) -{ - return BadRequest; -} - -void -SRepXExtendedGrabDevice(ClientPtr client, int size, - xExtendedGrabDeviceReply* rep) -{ - char n; - swaps(&rep->sequenceNumber, n); - swaps(&rep->length, n); - WriteToClient(client, size, (char*)rep); -} diff --git a/Xi/extgrbdev.h b/Xi/extgrbdev.h deleted file mode 100644 index 6e3e371a5..000000000 --- a/Xi/extgrbdev.h +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Copyright 2007-2008 Peter Hutterer - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the "Software"), - * to deal in the Software without restriction, including without limitation - * the rights to use, copy, modify, merge, publish, distribute, sublicense, - * and/or sell copies of the Software, and to permit persons to whom the - * Software is furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice (including the next - * paragraph) shall be included in all copies or substantial portions of the - * Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL - * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING - * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER - * DEALINGS IN THE SOFTWARE. - * - * Author: Peter Hutterer, University of South Australia, NICTA - */ - -#ifdef HAVE_DIX_CONFIG_H -#include <dix-config.h> -#endif - -#ifndef EXTGRBDEV_H -#define EXTGRBDEV_H 1 - -int SProcXExtendedGrabDevice(ClientPtr /* client */ - ); - -int ProcXExtendedGrabDevice(ClientPtr /* client */ - ); - -void SRepXExtendedGrabDevice(ClientPtr client, - int size, - xExtendedGrabDeviceReply* rep); - -#endif /* EXTGRBDEV_H */ diff --git a/Xi/extinit.c b/Xi/extinit.c index 6779dc12c..f99b55513 100644 --- a/Xi/extinit.c +++ b/Xi/extinit.c @@ -82,7 +82,6 @@ SOFTWARE. #include "chgprop.h" #include "chgptr.h" #include "closedev.h" -#include "extgrbdev.h" #include "devbell.h" #include "getbmap.h" #include "getbmap.h" @@ -235,8 +234,7 @@ static int (*ProcIVector[])(ClientPtr) = { ProcXChangeDeviceHierarchy, /* 43 */ ProcXSetClientPointer, /* 44 */ ProcXGetClientPointer, /* 45 */ - ProcXiSelectEvent, /* 46 */ - ProcXExtendedGrabDevice /* 47 */ + ProcXiSelectEvent /* 46 */ }; /* For swapped clients */ @@ -287,8 +285,7 @@ static int (*SProcIVector[])(ClientPtr) = { SProcXChangeDeviceHierarchy, /* 43 */ SProcXSetClientPointer, /* 44 */ SProcXGetClientPointer, /* 45 */ - SProcXiSelectEvent, /* 46 */ - SProcXExtendedGrabDevice /* 47 */ + SProcXiSelectEvent /* 46 */ }; /***************************************************************** @@ -479,8 +476,6 @@ SReplyIDispatch(ClientPtr client, int len, xGrabDeviceReply * rep) (xQueryDevicePointerReply *) rep); else if (rep->RepType == X_GetClientPointer) SRepXGetClientPointer(client, len, (xGetClientPointerReply*) rep); - else if (rep->RepType == X_ExtendedGrabDevice) - SRepXExtendedGrabDevice(client, len, (xExtendedGrabDeviceReply*) rep); else { FatalError("XINPUT confused sending swapped reply"); } |