aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw/xwin/winmouse.c
diff options
context:
space:
mode:
Diffstat (limited to 'xorg-server/hw/xwin/winmouse.c')
-rw-r--r--xorg-server/hw/xwin/winmouse.c23
1 files changed, 6 insertions, 17 deletions
diff --git a/xorg-server/hw/xwin/winmouse.c b/xorg-server/hw/xwin/winmouse.c
index 62e3f79b4..efe71103c 100644
--- a/xorg-server/hw/xwin/winmouse.c
+++ b/xorg-server/hw/xwin/winmouse.c
@@ -241,23 +241,17 @@ winMouseWheel (ScreenPtr pScreen, int iDeltaZ)
void
winMouseButtonsSendEvent (int iEventType, int iButton)
{
- EventListPtr events;
- int i, nevents;
ValuatorMask mask;
if (g_winMouseButtonMap)
iButton = g_winMouseButtonMap[iButton];
valuator_mask_zero(&mask);
- GetEventList(&events);
- nevents = GetPointerEvents(events, g_pwinPointer, iEventType, iButton,
- POINTER_RELATIVE, &mask);
+ QueuePointerEvents(g_pwinPointer, iEventType, iButton,
+ POINTER_RELATIVE, &mask);
- for (i = 0; i < nevents; i++)
- mieqEnqueue(g_pwinPointer, (InternalEvent*)events[i].event);
-
- winDebug("winMouseButtonsSendEvent: iEventType: %d, iButton: %d, nEvents %d\n",
- iEventType, iButton, nevents);
+ winDebug("winMouseButtonsSendEvent: iEventType: %d, iButton: %d\n",
+ iEventType, iButton);
}
@@ -372,20 +366,15 @@ winMouseButtonsHandle (ScreenPtr pScreen,
*/
void winEnqueueMotion(int x, int y)
{
- int i, nevents;
int valuators[2];
ValuatorMask mask;
- EventListPtr events;
miPointerSetPosition(g_pwinPointer, POINTER_RELATIVE, &x, &y);
valuators[0] = x;
valuators[1] = y;
valuator_mask_set_range(&mask, 0, 2, valuators);
- GetEventList(&events);
- nevents = GetPointerEvents(events, g_pwinPointer, MotionNotify, 0,
- POINTER_ABSOLUTE | POINTER_SCREEN, &mask);
+ QueuePointerEvents(g_pwinPointer, MotionNotify, 0,
+ POINTER_ABSOLUTE | POINTER_SCREEN, &mask);
- for (i = 0; i < nevents; i++)
- mieqEnqueue(g_pwinPointer, (InternalEvent*)events[i].event);
}