Re: surface ++= ?

Charles Goodwin <[email protected]> Thu, 15 Apr 2004 21:07:58 +0000
Newsgroups gmane.comp.java.xwt.widgets
Organization XWT Foundation
Message-ID <[email protected]>
On Thu, 2004-04-15 at 16:48 -0400, Brian Alliet wrote:
> This should be pretty easy to solve. We could have the surface property 
> work backwards when it is put to. 'surface = true;' would just do 
> 'surface = true;' on all its children. Then you could just put a write 
> trap on surface to know when it changes. surface.t would be responsible 
> for doing a surface = true when it starts.

That'd work fine, although it's still 'slightly' hackish, but far better
than what we currently have.

> > However, if we want to do things like dragging tabs between frames, or
> > other such widget-moving-to-Surface stuff, this means we either:
> 
> Hmm.. that is a tricky one. I've been thinking about this for a while 
> and I can't think of anything good. The best idea I've had so far is 
> just notifying children when their parent changes (you wouldn't tell 
> them who their parent is, just that it changed) Children could then 
> reregister with the focus manger if necessary when their parent 
> changes.
> 
> Anybody else got any ideas?

Have the core put "true" to surface whenever a box changes parent and
getSurface() has changed.

That adds a little more overhead to switching boxes between parents but
it should be fairly neglible.
-- 
- Charlie

Charles Goodwin <[email protected]>
Online @ www.charlietech.com