ok,
just realized that you can accomplish something similar by using
navigators... just set creationPolicy="auto" and conditionally set the
selectedIndex... only it will just work under some particular
circumstances and is quite hacky.
i need to destroy children when the condition changes, to avoid
parameter problems... but still. that only leaves me with binding
issues.
OTOH, the ideal way would be to create a custom component that
implements IRepeater so that containers don't add it, and then play
with createChildrenFromDescriptors and such.
i just gave the latter a try and got it kinda working, but it would
take toooooooooo much time to make it work with bindings and stabilize
it. i give up.
c'mon adobe guys!
you can do it ;)
best,
Aldo
On 5/31/07, Aldo Bucchi <[EMAIL PROTECTED]> wrote:
> Hi Guys,
>
> Has anyone flirted with the idea of creating MXML
> conditional-structure components that can be used to dynamically
> generate interfaces??
>
> just to be more graphical... something like this
>
> <mx:Repeater id="rep2" dataProvider="{rep1.currentItem.elements('*')}">
>
> <foo:If condition="[EMAIL PROTECTED]'super'}">
>
> <foo:SuperLabel text="[EMAIL PROTECTED]"/>
>
> <foo:Else>
>
> <mx:Label text="[EMAIL PROTECTED]"/>
>
> </foo:Else>
>
> </foo:If>
>
> </mx:Repeater>
>
> it just makes a lot of sense...
> any ideas????
>
> best,
> Aldo
>
>
> --
> ::::: Aldo Bucchi :::::
> mobile +56 9 8429 8300
>
--
::::: Aldo Bucchi :::::
mobile +56 9 8429 8300