This fixes the close screen mess (crash reported by Thomas). Also hide the

private Exa screen definition. Properly cleanup on screen close and do
    not delete the private screen in the DriverFini call.
This commit is contained in:
Zack Rusin 2005-07-04 14:15:57 +00:00
commit e34f31762e
14 changed files with 447 additions and 353 deletions

View file

@ -249,92 +249,36 @@ ExaCheckPaintWindow (WindowPtr pWin, RegionPtr pRegion, int what)
fbPaintWindow (pWin, pRegion, what);
}
void
ExaCheckCopyWindow (WindowPtr pWin, DDXPointRec ptOldOrg, RegionPtr prgnSrc)
{
exaWaitSync (pWin->drawable.pScreen);
exaDrawableDirty ((DrawablePtr)pWin);
fbCopyWindow (pWin, ptOldOrg, prgnSrc);
}
#if EXA_MAX_FB > 1
void
ExaCheckPaintKey(DrawablePtr pDrawable,
RegionPtr pRegion,
CARD32 pixel,
int layer)
{
exaWaitSync (pDrawable->pScreen);
exaDrawableDirty (pDrawable);
fbOverlayPaintKey (pDrawable, pRegion, pixel, layer);
}
void
ExaCheckOverlayCopyWindow (WindowPtr pWin, DDXPointRec ptOldOrg, RegionPtr prgnSrc)
{
exaWaitSync (pWin->drawable.pScreen);
exaDrawableDirty ((DrawablePtr)pWin);
fbOverlayCopyWindow (pWin, ptOldOrg, prgnSrc);
}
#endif
void
ExaScreenInitAsync (ScreenPtr pScreen)
{
pScreen->GetImage = ExaCheckGetImage;
pScreen->GetSpans = ExaCheckGetSpans;
pScreen->PaintWindowBackground = ExaCheckPaintWindow;
pScreen->PaintWindowBorder = ExaCheckPaintWindow;
pScreen->CopyWindow = ExaCheckCopyWindow;
pScreen->BackingStoreFuncs.SaveAreas = ExaCheckSaveAreas;
pScreen->BackingStoreFuncs.RestoreAreas = ExaCheckRestoreAreas;
#ifdef RENDER
ExaPictureInitAsync (pScreen);
#endif
}
void
ExaCheckComposite (CARD8 op,
PicturePtr pSrc,
PicturePtr pMask,
PicturePtr pDst,
INT16 xSrc,
INT16 ySrc,
INT16 xMask,
INT16 yMask,
INT16 xDst,
INT16 yDst,
CARD16 width,
CARD16 height)
PicturePtr pSrc,
PicturePtr pMask,
PicturePtr pDst,
INT16 xSrc,
INT16 ySrc,
INT16 xMask,
INT16 yMask,
INT16 xDst,
INT16 yDst,
CARD16 width,
CARD16 height)
{
exaWaitSync (pDst->pDrawable->pScreen);
exaDrawableDirty (pDst->pDrawable);
fbComposite (op,
pSrc,
pMask,
pDst,
xSrc,
ySrc,
xMask,
yMask,
xDst,
yDst,
width,
height);
pSrc,
pMask,
pDst,
xSrc,
ySrc,
xMask,
yMask,
xDst,
yDst,
width,
height);
}
void
ExaPictureInitAsync (ScreenPtr pScreen)
{
PictureScreenPtr ps;
ps = GetPictureScreen(pScreen);
ps->Composite = ExaCheckComposite;
}
/*
* Only need to stall for copyarea/copyplane
*/