summaryrefslogtreecommitdiff
path: root/hw/xfree86/ramdac
diff options
context:
space:
mode:
authorEamon Walsh <ewalsh@tycho.nsa.gov>2008-08-27 19:27:13 -0400
committerEamon Walsh <ewalsh@tycho.nsa.gov>2008-08-27 19:27:13 -0400
commitec7907f8fa04dcff2649cc4846975844314f737e (patch)
tree29236baa9e98868c99fe5a18cb8aad0446d8a93c /hw/xfree86/ramdac
parent86898491497a43814caf42013651086e62fe6162 (diff)
Add an array of integers for use as per-screen cursor private keys.
Replaces the use of the screen pointer itself as the key, which was nice but won't work now that an array index is being stored.
Diffstat (limited to 'hw/xfree86/ramdac')
-rw-r--r--hw/xfree86/ramdac/xf86Cursor.c6
-rw-r--r--hw/xfree86/ramdac/xf86HWCurs.c4
2 files changed, 5 insertions, 5 deletions
diff --git a/hw/xfree86/ramdac/xf86Cursor.c b/hw/xfree86/ramdac/xf86Cursor.c
index 3c98f6e7d..be4fb908e 100644
--- a/hw/xfree86/ramdac/xf86Cursor.c
+++ b/hw/xfree86/ramdac/xf86Cursor.c
@@ -269,7 +269,7 @@ xf86CursorRealizeCursor(DeviceIntPtr pDev, ScreenPtr pScreen, CursorPtr pCurs)
&pScreen->devPrivates, xf86CursorScreenKey);
if (pCurs->refcnt <= 1)
- dixSetPrivate(&pCurs->devPrivates, pScreen, NULL);
+ dixSetPrivate(&pCurs->devPrivates, CursorScreenKey(pScreen), NULL);
return (*ScreenPriv->spriteFuncs->RealizeCursor)(pDev, pScreen, pCurs);
}
@@ -282,8 +282,8 @@ xf86CursorUnrealizeCursor(DeviceIntPtr pDev, ScreenPtr pScreen,
&pScreen->devPrivates, xf86CursorScreenKey);
if (pCurs->refcnt <= 1) {
- xfree(dixLookupPrivate(&pCurs->devPrivates, pScreen));
- dixSetPrivate(&pCurs->devPrivates, pScreen, NULL);
+ xfree(dixLookupPrivate(&pCurs->devPrivates, CursorScreenKey(pScreen)));
+ dixSetPrivate(&pCurs->devPrivates, CursorScreenKey(pScreen), NULL);
}
return (*ScreenPriv->spriteFuncs->UnrealizeCursor)(pDev, pScreen, pCurs);
diff --git a/hw/xfree86/ramdac/xf86HWCurs.c b/hw/xfree86/ramdac/xf86HWCurs.c
index d10e283d7..ea0523362 100644
--- a/hw/xfree86/ramdac/xf86HWCurs.c
+++ b/hw/xfree86/ramdac/xf86HWCurs.c
@@ -123,7 +123,7 @@ xf86SetCursor(ScreenPtr pScreen, CursorPtr pCurs, int x, int y)
return;
}
- bits = (unsigned char *)dixLookupPrivate(&pCurs->devPrivates, pScreen);
+ bits = dixLookupPrivate(&pCurs->devPrivates, CursorScreenKey(pScreen));
x -= infoPtr->pScrn->frameX0 + ScreenPriv->HotX;
y -= infoPtr->pScrn->frameY0 + ScreenPriv->HotY;
@@ -133,7 +133,7 @@ xf86SetCursor(ScreenPtr pScreen, CursorPtr pCurs, int x, int y)
#endif
if (!bits) {
bits = (*infoPtr->RealizeCursor)(infoPtr, pCurs);
- dixSetPrivate(&pCurs->devPrivates, pScreen, bits);
+ dixSetPrivate(&pCurs->devPrivates, CursorScreenKey(pScreen), bits);
}
if (!(infoPtr->Flags & HARDWARE_CURSOR_UPDATE_UNHIDDEN))