4381572
From 3323f7ac880d5a8261d5b22059374fc9de8ca683 Mon Sep 17 00:00:00 2001
4381572
From: Peter Hutterer <peter.hutterer@who-t.net>
4381572
Date: Wed, 25 Mar 2009 12:55:42 +1000
4381572
Subject: [PATCH] xfree86: fix SWCursor check in xf86CursorSetCursor.
4381572
4381572
Wrong check for inputInfo.pointer resulted in a SW cursor being rendered when
4381572
the pointer left the screen (in a Xinerama setup).
4381572
We must call the sprite rendering function if
4381572
- SW cursors are enabled, or
4381572
- The current device is not the VCP and not attached to the VCP.
4381572
4381572
Reported-by: Gordon Yuan <GordonYuan@viatech.com.cn>
4381572
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
4381572
---
4381572
 hw/xfree86/ramdac/xf86Cursor.c |    6 +++---
4381572
 1 files changed, 3 insertions(+), 3 deletions(-)
4381572
4381572
diff --git a/hw/xfree86/ramdac/xf86Cursor.c b/hw/xfree86/ramdac/xf86Cursor.c
4381572
index 2b73b16..896ed37 100644
4381572
--- a/hw/xfree86/ramdac/xf86Cursor.c
4381572
+++ b/hw/xfree86/ramdac/xf86Cursor.c
4381572
@@ -302,9 +302,9 @@ xf86CursorSetCursor(DeviceIntPtr pDev, ScreenPtr pScreen, CursorPtr pCurs,
4381572
 
4381572
 
4381572
     if (pCurs == NullCursor) {	/* means we're supposed to remove the cursor */
4381572
-        if (ScreenPriv->SWCursor || pDev != inputInfo.pointer)
4381572
-            (*ScreenPriv->spriteFuncs->SetCursor)(pDev, pScreen, NullCursor,
4381572
-                                                  x, y);
4381572
+        if (ScreenPriv->SWCursor ||
4381572
+            !(pDev == inputInfo.pointer || !pDev->isMaster && pDev->u.master == inputInfo.pointer))
4381572
+                (*ScreenPriv->spriteFuncs->SetCursor)(pDev, pScreen, NullCursor, x, y);
4381572
         else if (ScreenPriv->isUp) {
4381572
             xf86SetCursor(pScreen, NullCursor, x, y);
4381572
             ScreenPriv->isUp = FALSE;
4381572
-- 
4381572
1.6.0.6
4381572