mirror of
https://github.com/X11Libre/xserver.git
synced 2026-03-24 08:04:30 +00:00
composite: Support updating an arbitrary subtree
Rename compUpdateWindow to compPaintWindowToParent and split the child walk to compPaintChildrenToWindow. Calling compPaintChildrenToWindow allows an arbitrary subtree to be updated, instead of having to update all the windows. This will be used to make sure all the descendants are copied to the parent when the parent window contents need to be accessed in IncludeInferios sub-window mode. WindowRec has a new member 'damagedDescendants' that is used to keep track of which subtrees need updating. When a window is damaged, 'damagedDescendants' will be set for all the ancestors, and when a subtree is updated, the tree walk can be stopped early if no damaged descendants are present. CompScreenRec no longer needs the 'damaged' member since the root window's 'damagedDescendants' provides the same information. Signed-off-by: Ville Syrjälä <ville.syrjala@nokia.com> Signed-off-by: Keith Packard <keithp@keithp.com>
This commit is contained in:
committed by
Keith Packard
parent
b89e6dbdfb
commit
f3480286ae
@@ -145,7 +145,7 @@ compGetImage (DrawablePtr pDrawable,
|
||||
|
||||
pScreen->GetImage = cs->GetImage;
|
||||
if (pDrawable->type == DRAWABLE_WINDOW)
|
||||
compScreenUpdate (pScreen);
|
||||
compPaintChildrenToWindow ((WindowPtr) pDrawable);
|
||||
(*pScreen->GetImage) (pDrawable, sx, sy, w, h, format, planemask, pdstLine);
|
||||
cs->GetImage = pScreen->GetImage;
|
||||
pScreen->GetImage = compGetImage;
|
||||
@@ -161,7 +161,7 @@ static void compSourceValidate(DrawablePtr pDrawable,
|
||||
|
||||
pScreen->SourceValidate = cs->SourceValidate;
|
||||
if (pDrawable->type == DRAWABLE_WINDOW && subWindowMode == IncludeInferiors)
|
||||
compScreenUpdate (pScreen);
|
||||
compPaintChildrenToWindow ((WindowPtr) pDrawable);
|
||||
if (pScreen->SourceValidate)
|
||||
(*pScreen->SourceValidate) (pDrawable, x, y, width, height,
|
||||
subWindowMode);
|
||||
|
||||
Reference in New Issue
Block a user