This just reserves the slot in the ABI and adds the call to position
updates.  Confining cursors to CRTCs will come soon.

Signed-off-by: Adam Jackson <[email protected]>
---
 include/scrnintstr.h |    4 ++++
 mi/mipointer.c       |    3 +++
 2 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/include/scrnintstr.h b/include/scrnintstr.h
index 00d014c..2635d99 100644
--- a/include/scrnintstr.h
+++ b/include/scrnintstr.h
@@ -402,6 +402,9 @@ typedef    void (* DeviceCursorCleanupProcPtr)(
         DeviceIntPtr /* pDev */,
         ScreenPtr    /* pScreen */);
 
+typedef void (*ConstrainCursorHarderProcPtr)(
+       DeviceIntPtr, ScreenPtr, int *, int *);
+
 typedef struct _Screen {
     int                        myNum;  /* index of this instance in Screens[] 
*/
     ATOM               id;
@@ -468,6 +471,7 @@ typedef struct _Screen {
     /* Cursor Procedures */
 
     ConstrainCursorProcPtr     ConstrainCursor;
+    ConstrainCursorHarderProcPtr ConstrainCursorHarder;
     CursorLimitsProcPtr                CursorLimits;
     DisplayCursorProcPtr       DisplayCursor;
     RealizeCursorProcPtr       RealizeCursor;
diff --git a/mi/mipointer.c b/mi/mipointer.c
index 554397a..9bfabb7 100644
--- a/mi/mipointer.c
+++ b/mi/mipointer.c
@@ -529,6 +529,9 @@ miPointerSetPosition(DeviceIntPtr pDev, int *x, int *y)
     if (*y >= pPointer->limits.y2)
        *y = pPointer->limits.y2 - 1;
 
+    if (pScreen->ConstrainCursorHarder)
+       pScreen->ConstrainCursorHarder(pDev, pScreen, x, y);
+
     if (pPointer->x == *x && pPointer->y == *y && 
             pPointer->pScreen == pScreen) 
         return;
-- 
1.7.3.4

_______________________________________________
[email protected]: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to