diff options
author | marha <marha@users.sourceforge.net> | 2014-10-12 21:11:32 +0200 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2014-10-12 21:38:35 +0200 |
commit | 1a83b8e49a75e2dab63805de25e384e0e38c27ed (patch) | |
tree | 5280fe2a1bd2ce227e4bce9ce06134986e181de1 /xorg-server/mi/mioverlay.c | |
parent | 4aea4b223604c589828beb1145875a5fbcc41eed (diff) | |
parent | 9480392b8817f8bfa79cbc694ff039a73fc0a57f (diff) | |
download | vcxsrv-1a83b8e49a75e2dab63805de25e384e0e38c27ed.tar.gz vcxsrv-1a83b8e49a75e2dab63805de25e384e0e38c27ed.tar.bz2 vcxsrv-1a83b8e49a75e2dab63805de25e384e0e38c27ed.zip |
Merge remote-tracking branch 'origin/released'
Conflicts:
mesalib/src/glsl/glsl_symbol_table.h
mesalib/src/mesa/drivers/common/meta_blit.c
xorg-server/dix/dispatch.c
xorg-server/glx/indirect_dispatch.c
xorg-server/glx/indirect_dispatch_swap.c
xorg-server/mi/miexpose.c
Diffstat (limited to 'xorg-server/mi/mioverlay.c')
-rw-r--r-- | xorg-server/mi/mioverlay.c | 70 |
1 files changed, 18 insertions, 52 deletions
diff --git a/xorg-server/mi/mioverlay.c b/xorg-server/mi/mioverlay.c index ef67f386d..9df98185b 100644 --- a/xorg-server/mi/mioverlay.c +++ b/xorg-server/mi/mioverlay.c @@ -83,7 +83,7 @@ static void miOverlayMarkUnrealizedWindow(WindowPtr, WindowPtr, Bool); static int miOverlayValidateTree(WindowPtr, WindowPtr, VTKind); static void miOverlayHandleExposures(WindowPtr); static void miOverlayMoveWindow(WindowPtr, int, int, WindowPtr, VTKind); -static void miOverlayWindowExposures(WindowPtr, RegionPtr, RegionPtr); +static void miOverlayWindowExposures(WindowPtr, RegionPtr); static void miOverlayResizeWindow(WindowPtr, int, int, unsigned int, unsigned int, WindowPtr); static void miOverlayClearToBackground(WindowPtr, int, int, int, int, Bool); @@ -831,7 +831,7 @@ miOverlayHandleExposures(WindowPtr pWin) miOverlayScreenPtr pPriv = MIOVERLAY_GET_SCREEN_PRIVATE(pScreen); WindowPtr pChild; ValidatePtr val; - void (*WindowExposures) (WindowPtr, RegionPtr, RegionPtr); + WindowExposuresProcPtr WindowExposures; WindowExposures = pWin->drawable.pScreen->WindowExposures; if (pPriv->underlayMarked) { @@ -853,8 +853,7 @@ miOverlayHandleExposures(WindowPtr pWin) } RegionUninit(&mival->borderExposed); - (*WindowExposures) (pTree->pWin, &mival->exposed, - NullRegion); + (*WindowExposures) (pTree->pWin, &mival->exposed); RegionUninit(&mival->exposed); } free(mival); @@ -890,7 +889,7 @@ miOverlayHandleExposures(WindowPtr pWin) if (RegionNotEmpty(&val->after.borderExposed)) { miPaintWindow(pChild, &val->after.borderExposed, PW_BORDER); } - (*WindowExposures) (pChild, &val->after.exposed, NullRegion); + (*WindowExposures) (pChild, &val->after.exposed); } RegionUninit(&val->after.borderExposed); RegionUninit(&val->after.exposed); @@ -984,42 +983,23 @@ miOverlayMoveWindow(WindowPtr pWin, #endif static void -miOverlayWindowExposures(WindowPtr pWin, - RegionPtr prgn, RegionPtr other_exposed) +miOverlayWindowExposures(WindowPtr pWin, RegionPtr prgn) { RegionPtr exposures = prgn; - if ((prgn && !RegionNil(prgn)) || - (exposures && !RegionNil(exposures)) || other_exposed) { + if (prgn && !RegionNil(prgn)) { RegionRec expRec; - int clientInterested; - - clientInterested = (pWin->eventMask | wOtherEventMasks(pWin)) & - ExposureMask; - if (other_exposed) { - if (exposures) { - RegionUnion(other_exposed, exposures, other_exposed); - if (exposures != prgn) - RegionDestroy(exposures); - } - exposures = other_exposed; - } - if (clientInterested && exposures && - (RegionNumRects(exposures) > RECTLIMIT)) { + int clientInterested = + (pWin->eventMask | wOtherEventMasks(pWin)) & ExposureMask; + if (clientInterested && (RegionNumRects(prgn) > RECTLIMIT)) { ScreenPtr pScreen = pWin->drawable.pScreen; miOverlayScreenPtr pPriv = MIOVERLAY_GET_SCREEN_PRIVATE(pScreen); BoxRec box; - box = *RegionExtents(exposures); - if (exposures == prgn) { - exposures = &expRec; - RegionInit(exposures, &box, 1); - RegionReset(prgn, &box); - } - else { - RegionReset(exposures, &box); - RegionUnion(prgn, prgn, exposures); - } + box = *RegionExtents(prgn); + exposures = &expRec; + RegionInit(exposures, &box, 1); + RegionReset(prgn, &box); /* This is the only reason why we are replacing mi's version of this file */ @@ -1031,21 +1011,14 @@ miOverlayWindowExposures(WindowPtr pWin, else RegionIntersect(prgn, prgn, &pWin->clipList); } - if (prgn && !RegionNil(prgn)) - miPaintWindow(pWin, prgn, PW_BACKGROUND); - if (clientInterested && exposures && !RegionNil(exposures)) + miPaintWindow(pWin, prgn, PW_BACKGROUND); + if (clientInterested) miSendExposures(pWin, exposures, pWin->drawable.x, pWin->drawable.y); - if (exposures == &expRec) { + if (exposures == &expRec) RegionUninit(exposures); - } - else if (exposures && exposures != prgn && exposures != other_exposed) - RegionDestroy(exposures); - if (prgn) - RegionEmpty(prgn); + RegionEmpty(prgn); } - else if (exposures && exposures != prgn) - RegionDestroy(exposures); } typedef struct { @@ -1495,11 +1468,7 @@ miOverlaySetShape(WindowPtr pWin, int kind) if (WasViewable) { (*pScreen->MarkOverlappedWindows) (pWin, pWin, NULL); - (*pScreen->ValidateTree) (pWin->parent, NullWindow, VTOther); - } - - if (WasViewable) { (*pScreen->HandleExposures) (pWin->parent); if (pScreen->PostValidateTree) (*pScreen->PostValidateTree) (pWin->parent, NullWindow, @@ -1596,7 +1565,6 @@ miOverlayClearToBackground(WindowPtr pWin, miOverlayTreePtr pTree = MIOVERLAY_GET_WINDOW_TREE(pWin); BoxRec box; RegionRec reg; - RegionPtr pBSReg = NullRegion; ScreenPtr pScreen = pWin->drawable.pScreen; miOverlayScreenPtr pScreenPriv = MIOVERLAY_GET_SCREEN_PRIVATE(pScreen); RegionPtr clipList; @@ -1640,12 +1608,10 @@ miOverlayClearToBackground(WindowPtr pWin, RegionIntersect(®, ®, clipList); if (generateExposures) - (*pScreen->WindowExposures) (pWin, ®, pBSReg); + (*pScreen->WindowExposures) (pWin, ®); else if (pWin->backgroundState != None) miPaintWindow(pWin, ®, PW_BACKGROUND); RegionUninit(®); - if (pBSReg) - RegionDestroy(pBSReg); } /****************************************************************/ |