aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw/xnest
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2011-05-16 08:06:12 +0000
committermarha <marha@users.sourceforge.net>2011-05-16 08:06:12 +0000
commit08cbf3b50bfe713044f36b363c73768cd042f13c (patch)
tree6be4c5dd7f5bc2f058228b2a2fa747a4d7666dc5 /xorg-server/hw/xnest
parentd8c3e3d2ba88d6b87a718aef7f4fb4627113eb52 (diff)
downloadvcxsrv-08cbf3b50bfe713044f36b363c73768cd042f13c.tar.gz
vcxsrv-08cbf3b50bfe713044f36b363c73768cd042f13c.tar.bz2
vcxsrv-08cbf3b50bfe713044f36b363c73768cd042f13c.zip
xserver xkeyboar-config mesa git update 16 May 2011
Diffstat (limited to 'xorg-server/hw/xnest')
-rw-r--r--xorg-server/hw/xnest/Events.c36
-rw-r--r--xorg-server/hw/xnest/Init.c4
2 files changed, 10 insertions, 30 deletions
diff --git a/xorg-server/hw/xnest/Events.c b/xorg-server/hw/xnest/Events.c
index 5c800860a..619427ded 100644
--- a/xorg-server/hw/xnest/Events.c
+++ b/xorg-server/hw/xnest/Events.c
@@ -43,8 +43,6 @@ is" without express or implied warranty.
CARD32 lastEventTime = 0;
-extern EventList *xnestEvents;
-
void
ProcessInputEvents(void)
{
@@ -104,23 +102,17 @@ xnestCollectExposures(void)
void
xnestQueueKeyEvent(int type, unsigned int keycode)
{
- int i, n;
-
- GetEventList(&xnestEvents);
lastEventTime = GetTimeInMillis();
- n = GetKeyboardEvents(xnestEvents, xnestKeyboardDevice, type, keycode, NULL);
- for (i = 0; i < n; i++)
- mieqEnqueue(xnestKeyboardDevice, (InternalEvent*)(xnestEvents + i)->event);
+ QueueKeyboardEvents(xnestKeyboardDevice, type, keycode, NULL);
}
void
xnestCollectEvents(void)
{
XEvent X;
- int i, n, valuators[2];
+ int valuators[2];
ValuatorMask mask;
ScreenPtr pScreen;
- GetEventList(&xnestEvents);
while (XCheckIfEvent(xnestDisplay, &X, xnestNotExposurePredicate, NULL)) {
switch (X.type) {
@@ -138,20 +130,16 @@ xnestCollectEvents(void)
valuator_mask_set_range(&mask, 0, 0, NULL);
xnestUpdateModifierState(X.xkey.state);
lastEventTime = GetTimeInMillis();
- n = GetPointerEvents(xnestEvents, xnestPointerDevice, ButtonPress,
- X.xbutton.button, POINTER_RELATIVE, &mask);
- for (i = 0; i < n; i++)
- mieqEnqueue(xnestPointerDevice, (InternalEvent*)(xnestEvents + i)->event);
+ QueuePointerEvents(xnestPointerDevice, ButtonPress,
+ X.xbutton.button, POINTER_RELATIVE, &mask);
break;
case ButtonRelease:
valuator_mask_set_range(&mask, 0, 0, NULL);
xnestUpdateModifierState(X.xkey.state);
lastEventTime = GetTimeInMillis();
- n = GetPointerEvents(xnestEvents, xnestPointerDevice, ButtonRelease,
- X.xbutton.button, POINTER_RELATIVE, &mask);
- for (i = 0; i < n; i++)
- mieqEnqueue(xnestPointerDevice, (InternalEvent*)(xnestEvents + i)->event);
+ QueuePointerEvents(xnestPointerDevice, ButtonRelease,
+ X.xbutton.button, POINTER_RELATIVE, &mask);
break;
case MotionNotify:
@@ -159,10 +147,8 @@ xnestCollectEvents(void)
valuators[1] = X.xmotion.y;
valuator_mask_set_range(&mask, 0, 2, valuators);
lastEventTime = GetTimeInMillis();
- n = GetPointerEvents(xnestEvents, xnestPointerDevice, MotionNotify,
- 0, POINTER_ABSOLUTE, &mask);
- for (i = 0; i < n; i++)
- mieqEnqueue(xnestPointerDevice, (InternalEvent*)(xnestEvents + i)->event);
+ QueuePointerEvents(xnestPointerDevice, MotionNotify,
+ 0, POINTER_ABSOLUTE, &mask);
break;
case FocusIn:
@@ -193,10 +179,8 @@ xnestCollectEvents(void)
valuators[1] = X.xcrossing.y;
valuator_mask_set_range(&mask, 0, 2, valuators);
lastEventTime = GetTimeInMillis();
- n = GetPointerEvents(xnestEvents, xnestPointerDevice, MotionNotify,
- 0, POINTER_ABSOLUTE, &mask);
- for (i = 0; i < n; i++)
- mieqEnqueue(xnestPointerDevice, (InternalEvent*)(xnestEvents + i)->event);
+ QueuePointerEvents(xnestPointerDevice, MotionNotify,
+ 0, POINTER_ABSOLUTE, &mask);
xnestDirectInstallColormaps(pScreen);
}
}
diff --git a/xorg-server/hw/xnest/Init.c b/xorg-server/hw/xnest/Init.c
index 8a90cc65e..ee74101d2 100644
--- a/xorg-server/hw/xnest/Init.c
+++ b/xorg-server/hw/xnest/Init.c
@@ -45,8 +45,6 @@ is" without express or implied warranty.
Bool xnestDoFullGeneration = True;
-EventList *xnestEvents = NULL;
-
void
InitOutput(ScreenInfo *screenInfo, int argc, char *argv[])
{
@@ -100,8 +98,6 @@ InitInput(int argc, char *argv[])
if (rc != Success)
FatalError("Failed to init Xnest default devices.\n");
- GetEventList(&xnestEvents);
-
mieqInit();
AddEnabledDevice(XConnectionNumber(xnestDisplay));