[PATCH v2 2/4] composite: Initialize borderClip with current values

ville.syrjala at nokia.com ville.syrjala at nokia.com
Mon Dec 27 05:24:11 PST 2010


From: Ville Syrjälä <ville.syrjala at nokia.com>

ValidateTree needs a valid borderClip so initialize the parent
constrained border clip with the window's current borderClip
in compRedirectWindow.

Signed-off-by: Ville Syrjälä <ville.syrjala at nokia.com>
Reviewed-by: Adam Jackson <ajax at redhat.com>
---
 composite/compalloc.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/composite/compalloc.c b/composite/compalloc.c
index 1138b9a..0ad1740 100644
--- a/composite/compalloc.c
+++ b/composite/compalloc.c
@@ -134,9 +134,11 @@ compRedirectWindow (ClientPtr pClient, WindowPtr pWin, int update)
 	    EnableMapUnmapEvents (pWin);
 	}
 
+	/* Make sure our borderClip is correct for ValidateTree */
 	RegionNull(&cw->borderClip);
-	cw->borderClipX = 0;
-	cw->borderClipY = 0;
+	RegionCopy(&cw->borderClip, &pWin->borderClip);
+	cw->borderClipX = pWin->drawable.x;
+	cw->borderClipY = pWin->drawable.y;
 	cw->update = CompositeRedirectAutomatic;
 	cw->clients = 0;
 	cw->oldx = COMP_ORIGIN_INVALID;
-- 
1.7.2.2



More information about the xorg-devel mailing list