Hi
I tried to change the gap of a vertical layout at runtime using a Slider
that change gap value:
<fx:Script>
<![CDATA[
private function onValueChange(event:Event):void
{
vlg.gap = slider_gap.value;
}
]]>
</fx:Script>
<js:beads>
<js:VerticalLayoutWithPaddingAndGap id="vlg" gap="10"/>
</js:beads>
<j:Slider id="slider_gap" width="250" value="10" minimum="0" maximum=
"100"
valueChange="onValueChange(event)"/>
But this not work.
Seems that layout once is set can't be changed, or there's no call of type
"doLayout" or something like this after setup again the gap value. I tried
to recall "layout()" method to see what happen but gives error
TypeError: undefined is not an object (evaluating 'this.host.getLayoutHost')
Is out layout system not prepared to do this or there's a way to call a
relayout in some way after set gap or padding in a layout class?
thanks
--
Carlos Rovira
http://about.me/carlosrovira