static void compGetSpans(DrawablePtr pDrawable, int wMax, DDXPointPtr ppt, int *pwidth, int nspans, char *pdstStart) { ScreenPtr pScreen = pDrawable->pScreen; CompScreenPtr cs = GetCompScreen(pScreen); pScreen->GetSpans = cs->GetSpans; if (pDrawable->type == DRAWABLE_WINDOW) compPaintChildrenToWindow((WindowPtr) pDrawable); (*pScreen->GetSpans) (pDrawable, wMax, ppt, pwidth, nspans, pdstStart); cs->GetSpans = pScreen->GetSpans; pScreen->GetSpans = compGetSpans; }
static void compGetImage(DrawablePtr pDrawable, int sx, int sy, int w, int h, unsigned int format, unsigned long planemask, char *pdstLine) { ScreenPtr pScreen = pDrawable->pScreen; CompScreenPtr cs = GetCompScreen(pScreen); pScreen->GetImage = cs->GetImage; if (pDrawable->type == DRAWABLE_WINDOW) compPaintChildrenToWindow((WindowPtr) pDrawable); (*pScreen->GetImage) (pDrawable, sx, sy, w, h, format, planemask, pdstLine); cs->GetImage = pScreen->GetImage; pScreen->GetImage = compGetImage; }
static void compSourceValidate(DrawablePtr pDrawable, int x, int y, int width, int height, unsigned int subWindowMode) { ScreenPtr pScreen = pDrawable->pScreen; CompScreenPtr cs = GetCompScreen(pScreen); pScreen->SourceValidate = cs->SourceValidate; if (pDrawable->type == DRAWABLE_WINDOW && subWindowMode == IncludeInferiors) compPaintChildrenToWindow((WindowPtr) pDrawable); if (pScreen->SourceValidate) (*pScreen->SourceValidate) (pDrawable, x, y, width, height, subWindowMode); cs->SourceValidate = pScreen->SourceValidate; pScreen->SourceValidate = compSourceValidate; }
static void compScreenUpdate(ScreenPtr pScreen) { compCheckTree(pScreen); compPaintChildrenToWindow(pScreen->root); }