mirror of
https://gitlab.freedesktop.org/xorg/xserver.git
synced 2026-01-04 14:30:13 +01:00
damage: Must translate initial window damage by window offset
Damage is reported relative to the drawable origin, but the window borderClip is absolute. Translate the region by the window position before reporting damage to adjust. Reported-by: Adam Jackson <ajax@redhat.com> Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Adam Jackson <ajax@redhat.com>
This commit is contained in:
parent
8010d3a48b
commit
7d3d4ae55d
1 changed files with 2 additions and 0 deletions
|
|
@ -223,7 +223,9 @@ ProcDamageCreate(ClientPtr client)
|
|||
|
||||
if (pDrawable->type == DRAWABLE_WINDOW) {
|
||||
pRegion = &((WindowPtr) pDrawable)->borderClip;
|
||||
RegionTranslate(pRegion, -pDrawable->x, -pDrawable->y);
|
||||
DamageReportDamage(pDamageExt->pDamage, pRegion);
|
||||
RegionTranslate(pRegion, pDrawable->x, pDrawable->y);
|
||||
}
|
||||
|
||||
return Success;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue