mi: Use GC clipregion instead of drawable in miDoCopy/miCopyArea

As discussed in issue #829 the "mi: Shortcut miDoCopy/miCopyArea based
on clipList" change leads to pointer-trails (area under pointer not
restored when it moves) when using a software cursor.

Checking pGC->pCompositeClip instead of pDstDrawable->clipList fixes
this problem.

Fixes: #829
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
This commit is contained in:
Hans de Goede 2019-08-01 12:38:35 +02:00 committed by Adam Jackson
parent 0aaac8d783
commit fbd2bb9dd0
2 changed files with 2 additions and 2 deletions

View File

@ -98,7 +98,7 @@ miCopyArea(DrawablePtr pSrcDrawable,
/* If the destination is clipped away, this is easy */
if (pDstDrawable->type == DRAWABLE_WINDOW &&
RegionNil(&((WindowPtr)pDstDrawable)->clipList))
RegionNil(pGC->pCompositeClip))
return NULL;
/* clip the source */

View File

@ -154,7 +154,7 @@ miDoCopy(DrawablePtr pSrcDrawable,
/* Short cut for unmapped or fully clipped windows */
if (pDstDrawable->type == DRAWABLE_WINDOW &&
RegionNil(&((WindowPtr)pDstDrawable)->clipList)) {
RegionNil(pGC->pCompositeClip)) {
return NULL;
}