summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Stone <daniel@fooishbar.org>2006-10-25 01:10:20 +0300
committerDaniel Stone <daniels@endtroducing.fooishbar.org>2006-10-25 01:10:20 +0300
commitb1debebf8fe20ded20ba27e871fd1a6a9de029e3 (patch)
tree8d8216dd0ffc245042a0844440dc55abbc0b9c23
parentb9e180e632d04bf685ade9e32bd0b20882794486 (diff)
mi: remove mi motion history
This is now unneeded as we do motion history in the DIX.
-rw-r--r--hw/xfree86/loader/misym.c2
-rw-r--r--mi/mipointer.c74
-rw-r--r--mi/mipointer.h8
-rw-r--r--mi/mipointrst.h9
4 files changed, 0 insertions, 93 deletions
diff --git a/hw/xfree86/loader/misym.c b/hw/xfree86/loader/misym.c
index 3f959faa2..46d6a024d 100644
--- a/hw/xfree86/loader/misym.c
+++ b/hw/xfree86/loader/misym.c
@@ -191,8 +191,6 @@ _X_HIDDEN void *miLookupTab[] = {
SYMFUNC(miSegregateChildren)
SYMFUNC(miHookInitVisuals)
SYMFUNC(miPointerAbsoluteCursor)
- SYMFUNC(miPointerGetMotionEvents)
- SYMFUNC(miPointerGetMotionBufferSize)
SYMFUNC(miOverlayCopyUnderlay)
SYMFUNC(miOverlaySetTransFunction)
SYMFUNC(miOverlayCollectUnderlayRegions)
diff --git a/mi/mipointer.c b/mi/mipointer.c
index 7f850adde..679b7602f 100644
--- a/mi/mipointer.c
+++ b/mi/mipointer.c
@@ -128,7 +128,6 @@ miPointerInitialize (pScreen, spriteFuncs, screenFuncs, waitForUpdate)
miPointer.confined = FALSE;
miPointer.x = 0;
miPointer.y = 0;
- miPointer.history_start = miPointer.history_end = 0;
return TRUE;
}
@@ -267,39 +266,6 @@ miPointerWarpCursor (pScreen, x, y)
* Pointer/CursorDisplay interface routines
*/
-_X_EXPORT int
-miPointerGetMotionBufferSize ()
-{
- return MOTION_SIZE;
-}
-
-_X_EXPORT int
-miPointerGetMotionEvents (pPtr, coords, start, stop, pScreen)
- DeviceIntPtr pPtr;
- xTimecoord *coords;
- unsigned long start, stop;
- ScreenPtr pScreen;
-{
- int i;
- int count = 0;
- miHistoryPtr h;
-
- for (i = miPointer.history_start; i != miPointer.history_end;)
- {
- h = &miPointer.history[i];
- if (h->event.time >= stop)
- break;
- if (h->event.time >= start)
- {
- *coords++ = h->event;
- count++;
- }
- if (++i == MOTION_SIZE) i = 0;
- }
- return count;
-}
-
-
/*
* miPointerUpdate
*
@@ -518,44 +484,4 @@ miPointerMoved (DeviceIntPtr pDev, ScreenPtr pScreen, int x, int y,
if(!miPointer.pCursor->bits->emptyMask)
(*pScreenPriv->spriteFuncs->MoveCursor) (pScreen, x, y);
}
-
- miPointerUpdateHistory(pDev, pScreen, x, y, time);
-}
-
-/* The pointer has moved to x, y; update the motion history. */
-void
-miPointerUpdateHistory (DeviceIntPtr pDev, ScreenPtr pScreen, int x, int y,
- unsigned long time)
-{
- miHistoryPtr history;
- int prev, end, start;
-
- miPointer.x = x;
- miPointer.y = y;
- miPointer.pScreen = pScreen;
-
- end = miPointer.history_end;
- start = miPointer.history_start;
- prev = end - 1;
- if (end == 0)
- prev = MOTION_SIZE - 1;
- history = &miPointer.history[prev];
- if (end == start || history->event.time != time)
- {
- history = &miPointer.history[end];
- if (++end == MOTION_SIZE)
- end = 0;
- if (end == start)
- {
- start = end + 1;
- if (start == MOTION_SIZE)
- start = 0;
- miPointer.history_start = start;
- }
- miPointer.history_end = end;
- }
- history->event.x = x;
- history->event.y = y;
- history->event.time = time;
- history->pScreen = pScreen;
}
diff --git a/mi/mipointer.h b/mi/mipointer.h
index 21b55fac7..30e89444b 100644
--- a/mi/mipointer.h
+++ b/mi/mipointer.h
@@ -181,14 +181,6 @@ extern void miPointerMoved(
int y,
unsigned long time);
-/* Updates the event history. */
-extern void miPointerUpdateHistory(
- DeviceIntPtr pDev,
- ScreenPtr pScreen,
- int x,
- int y,
- unsigned long time);
-
extern int miPointerScreenIndex;
#endif /* MIPOINTER_H */
diff --git a/mi/mipointrst.h b/mi/mipointrst.h
index 2ebf3278c..a80c52e7a 100644
--- a/mi/mipointrst.h
+++ b/mi/mipointrst.h
@@ -32,13 +32,6 @@ in this Software without prior written authorization from The Open Group.
#include "mipointer.h"
#include "scrnintstr.h"
-#define MOTION_SIZE 256
-
-typedef struct {
- xTimecoord event;
- ScreenPtr pScreen;
-} miHistoryRec, *miHistoryPtr;
-
typedef struct {
ScreenPtr pScreen; /* current screen */
ScreenPtr pSpriteScreen;/* screen containing current sprite */
@@ -48,8 +41,6 @@ typedef struct {
Bool confined; /* pointer can't change screens */
int x, y; /* hot spot location */
int devx, devy; /* sprite position */
- miHistoryRec history[MOTION_SIZE];
- int history_start, history_end;
} miPointerRec, *miPointerPtr;
typedef struct {