On Thu, Mar 27, 2008 at 12:16 PM, Johan Compagner <[EMAIL PROTECTED]> wrote:
> isnt it possible that we have a transparent resolver or something like that
>  that is the closure?
>  so that that one can be set visible or not
>  and then we dont have to touch the children those are just one step deeper
>  (but not really)

you kinda hit the nail on the head: the enclosure IS an auto component
that IS a transparent resolver

the problem with this is that:
it is auto - so it only exists during render time (autos are removed
in detach())
it is a transparent resolver - that means it is not a parent of the
components that are inside the enclosure markup.

i was thinking about changing it. making it a non-auto
webmarkupcontainer that is not transparent, and actually rewiring the
children properly, but that can get hairy also in case users expect
getparent() to return a certain thing...

-igor



>

>  johan
>
>
>  On Thu, Mar 27, 2008 at 6:20 PM, Igor Vaynberg <[EMAIL PROTECTED]>
>
>
> wrote:
>
>  > well, the problem here is a bit more complicated.
>  >
>  > what if the user overrides isivisible. i think what we want here is
>  > another flag, kind of like isrenderallowed, but something that we can
>  > push...thoughts?
>  >
>  > -igor
>  >
>  >
>  > On Thu, Mar 27, 2008 at 8:47 AM, Johan Compagner <[EMAIL PROTECTED]>
>  > wrote:
>  > > the problem with setVisible is that it is a version change..
>  > >  So if we disable that quickly before changing the variable then its
>  > fine by
>  > >  me to change that
>  > >  That can be default behavior by the way if you ask me
>  > >
>  > >  component.setVersioned(false)
>  > >  component.doWhatYouWant()
>  > >  component.setVersioned(true)
>  > >
>  > >
>  > >  johan
>  > >
>  > >
>  > >  On Thu, Mar 27, 2008 at 9:05 AM, Igor Vaynberg <[EMAIL PROTECTED]
>  > >
>  > >
>  > >
>  > > wrote:
>  > >
>  > >  > i guess all this nastiness stems from the facts that we resolve
>  > >  > enclosures at render time and at that time we restrict calls to
>  > >  > setvisible() because we consider it a hierarchy change.
>  > >  >
>  > >  > if we relax that at least for isvisible() calls then inside the
>  > >  > enclosureresolver all we have to do is iterate over its direct
>  > >  > children and call setvisible(false) on them if enclosure is hidden.
>  > >  >
>  > >  > -igor
>  > >  >
>  > >  >
>  > >  > On Thu, Mar 27, 2008 at 12:43 AM, Igor Vaynberg <
>  > [EMAIL PROTECTED]>
>  > >  > wrote:
>  > >  > > ive just attached a draft patch to WICKET-1391. its kinda hacky, so
>  > i
>  > >  > >  want to see if anyone can come up with a more elegant way to do
>  > this.
>  > >  > >
>  > >  > >  -igor
>  > >  > >
>  > >  >
>  > >
>  >
>

Reply via email to