From 6beb2364f38f5e53b0acb744ffc8225c9c13e492 Mon Sep 17 00:00:00 2001 From: Jay Sorg Date: Tue, 28 Jan 2014 10:41:32 -0800 Subject: xorg: work on xorg driver --- xorg/server/module/rdpImageGlyphBlt.c | 57 +++++------------------------------ 1 file changed, 7 insertions(+), 50 deletions(-) (limited to 'xorg/server/module/rdpImageGlyphBlt.c') diff --git a/xorg/server/module/rdpImageGlyphBlt.c b/xorg/server/module/rdpImageGlyphBlt.c index 5a5ceca2..74693fd9 100644 --- a/xorg/server/module/rdpImageGlyphBlt.c +++ b/xorg/server/module/rdpImageGlyphBlt.c @@ -39,17 +39,6 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #define LLOGLN(_level, _args) \ do { if (_level < LOG_LEVEL) { ErrorF _args ; ErrorF("\n"); } } while (0) -/******************************************************************************/ -static void -rdpImageGlyphBltPre(rdpPtr dev, rdpClientCon *clientCon, - int cd, RegionPtr clip_reg, - DrawablePtr pDrawable, GCPtr pGC, - int x, int y, unsigned int nglyph, - CharInfoPtr *ppci, pointer pglyphBase, - BoxPtr box) -{ -} - /******************************************************************************/ static void rdpImageGlyphBltOrg(DrawablePtr pDrawable, GCPtr pGC, @@ -63,34 +52,6 @@ rdpImageGlyphBltOrg(DrawablePtr pDrawable, GCPtr pGC, GC_OP_EPILOGUE(pGC); } -/******************************************************************************/ -static void -rdpImageGlyphBltPost(rdpPtr dev, rdpClientCon *clientCon, - int cd, RegionPtr clip_reg, - DrawablePtr pDrawable, GCPtr pGC, - int x, int y, unsigned int nglyph, - CharInfoPtr *ppci, pointer pglyphBase, - BoxPtr box) -{ - RegionRec reg; - - if (cd == XRDP_CD_NODRAW) - { - return; - } - if (!XRDP_DRAWABLE_IS_VISIBLE(dev, pDrawable)) - { - return; - } - rdpRegionInit(®, box, 0); - if (cd == XRDP_CD_CLIP) - { - rdpRegionIntersect(®, clip_reg, ®); - } - rdpClientConAddDirtyScreenReg(dev, clientCon, ®); - rdpRegionUninit(®); -} - /******************************************************************************/ void rdpImageGlyphBlt(DrawablePtr pDrawable, GCPtr pGC, @@ -98,8 +59,8 @@ rdpImageGlyphBlt(DrawablePtr pDrawable, GCPtr pGC, CharInfoPtr *ppci, pointer pglyphBase) { rdpPtr dev; - rdpClientCon *clientCon; RegionRec clip_reg; + RegionRec reg; int cd; BoxRec box; @@ -107,24 +68,20 @@ rdpImageGlyphBlt(DrawablePtr pDrawable, GCPtr pGC, dev = rdpGetDevFromScreen(pGC->pScreen); dev->counts.rdpImageGlyphBltCallCount++; GetTextBoundingBox(pDrawable, pGC->font, x, y, nglyph, &box); + rdpRegionInit(®, &box, 0); rdpRegionInit(&clip_reg, NullBox, 0); cd = rdpDrawGetClip(dev, &clip_reg, pDrawable, pGC); LLOGLN(10, ("rdpImageGlyphBlt: cd %d", cd)); - clientCon = dev->clientConHead; - while (clientCon != NULL) + if (cd == XRDP_CD_CLIP) { - rdpImageGlyphBltPre(dev, clientCon, cd, &clip_reg, pDrawable, pGC, - x, y, nglyph, ppci, pglyphBase, &box); - clientCon = clientCon->next; + rdpRegionIntersect(®, &clip_reg, ®); } /* do original call */ rdpImageGlyphBltOrg(pDrawable, pGC, x, y, nglyph, ppci, pglyphBase); - clientCon = dev->clientConHead; - while (clientCon != NULL) + if (cd != XRDP_CD_NODRAW) { - rdpImageGlyphBltPost(dev, clientCon, cd, &clip_reg, pDrawable, pGC, - x, y, nglyph, ppci, pglyphBase, &box); - clientCon = clientCon->next; + rdpClientConAddAllReg(dev, ®, pDrawable); } rdpRegionUninit(&clip_reg); + rdpRegionUninit(®); } -- cgit v1.2.1