mirror of
https://github.com/X11Libre/xserver.git
synced 2026-09-26 21:12:25 +00:00
Move each screen's root-window pointer into ScreenRec.
Many references to the WindowTable array already had the corresponding screen pointer handy, which meant they usually looked like "WindowTable[pScreen->myNum]". Adding a field to ScreenRec instead of keeping this information in a parallel array simplifies those expressions, and eliminates a MAXSCREENS-sized array. Since dix uses this data, a screen private entry isn't appropriate. xf86-video-dummy currently uses WindowTable, so it needs to be updated to reflect this change. Signed-off-by: Jamey Sharp <jamey@minilop.net> Reviewed-by: Tiago Vignatti <tiago.vignatti@nokia.com> Tested-by: Tiago Vignatti <tiago.vignatti@nokia.com> (i686 GNU/Linux)
This commit is contained in:
parent
80b5d3a326
commit
e7fae9ecc4
52 changed files with 130 additions and 128 deletions
|
|
@ -405,7 +405,7 @@ miDCPutUpCursor (DeviceIntPtr pDev, ScreenPtr pScreen, CursorPtr pCursor,
|
|||
}
|
||||
pScreenPriv = (miDCScreenPtr)dixLookupPrivate(&pScreen->devPrivates,
|
||||
miDCScreenKey);
|
||||
pWin = WindowTable[pScreen->myNum];
|
||||
pWin = pScreen->root;
|
||||
pBuffer = MIDCBUFFER(pDev, pScreen);
|
||||
|
||||
#ifdef ARGB_CURSOR
|
||||
|
|
@ -448,7 +448,7 @@ miDCSaveUnderCursor (DeviceIntPtr pDev, ScreenPtr pScreen,
|
|||
pBuffer = MIDCBUFFER(pDev, pScreen);
|
||||
|
||||
pSave = pBuffer->pSave;
|
||||
pWin = WindowTable[pScreen->myNum];
|
||||
pWin = pScreen->root;
|
||||
if (!pSave || pSave->drawable.width < w || pSave->drawable.height < h)
|
||||
{
|
||||
if (pSave)
|
||||
|
|
@ -482,7 +482,7 @@ miDCRestoreUnderCursor (DeviceIntPtr pDev, ScreenPtr pScreen,
|
|||
pBuffer = MIDCBUFFER(pDev, pScreen);
|
||||
pSave = pBuffer->pSave;
|
||||
|
||||
pWin = WindowTable[pScreen->myNum];
|
||||
pWin = pScreen->root;
|
||||
if (!pSave)
|
||||
return FALSE;
|
||||
|
||||
|
|
@ -513,7 +513,7 @@ miDCDeviceInitialize(DeviceIntPtr pDev, ScreenPtr pScreen)
|
|||
goto failure;
|
||||
|
||||
dixSetPrivate(&pDev->devPrivates, miDCSpriteKey + pScreen->myNum, pBuffer);
|
||||
pWin = WindowTable[pScreen->myNum];
|
||||
pWin = pScreen->root;
|
||||
|
||||
pBuffer->pSourceGC = miDCMakeGC(pWin);
|
||||
if (!pBuffer->pSourceGC)
|
||||
|
|
|
|||
Loading…
Reference in a new issue