[PATCH 2/4] composite: Support updating an arbitrary subtree

Keith Packard keithp at keithp.com
Thu Dec 30 10:34:22 PST 2010


On Thu, 30 Dec 2010 14:56:19 +0200, Ville Syrjälä <ville.syrjala at nokia.com> wrote:
> On Wed, Dec 29, 2010 at 01:05:02PM -0800, ext Keith Packard wrote:
> > On Wed, 29 Dec 2010 15:04:29 +0200, ville.syrjala at nokia.com wrote:
> > > From: Ville Syrjälä <ville.syrjala at nokia.com>
> > > 
> > > Rename compScreenUpdate to compChildrenUpdate, and pass a window as
> > > the parameter. This allows an arbitrary subtree to be updated, instead
> > > of having to update all the windows. This will be used to make sure
> > > all the children have been updated when the parent window contents need
> > > to be accessed in IncludeInferios sub-window mode.
> > 
> > This change isn't right -- compWindowUpdate is already recursive, so
> > there's no need to walk across the children.
> 
> I wanted to avoid the copy from pWin to it's parent,

Probably cleaner to fix compWindowUpdate to just not do that then, which
would be easily done by passing pWin as the 'data' parameter to
TraverseTree and simply skipping that window in compWindowUpdateVisit.

> Right. I was thinking about making cs->damaged into a counter, but that
> would still cause needless tree walks if the damaged windows are in a
> different subtree. So yeah, marking the ancestors would be the best
> choice. I'll take a look at doing that.

I'd like to have the simpler fix now and the more complicated fix
later; that way we can separate the bug fix from the optimization.

-- 
keith.packard at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.x.org/archives/xorg-devel/attachments/20101230/68e186fd/attachment.pgp>


More information about the xorg-devel mailing list