actionscript 3 - How to iterate over tabs in flex tabbar -


I am a flex newbie. Some tabs in the Flex tabbar specified by the configuration need to be disabled. On the tab in the tab bar again I'm having trouble running from if I use the getChildAt () command, it does not disable the tab button, but the content of that tab button is not such a good thing.

Thanks and relation, captivated

While asking about the code, always Post the minimum test case getChildAt () will work, so there's something else going on with your code.

  & lt; Mx: script & gt; & Lt ;! [CDATA [import mx.events.ItemClickEvent; Import mx.controls.tabBarClasses.Tab; Private Function Clickthab (Event: ItemClick Event): Zero {var Target: Tabbar = Event. Targeted as Tabbar; Var currTab: Tab; Var parity: int = event.index & amp; 1; / * Disable all tabs / identical equality on indexes as tabs clicked; Enable tabs of opposite parity * / for (var i = 0; i & lt; target.numChildren; ++ i) {currTab = target.getChildAt (i) in the form of tabs; CurrTab.enabled = (i & amp; 1) ^ parity; }}]] & Gt; & Lt; / Mx: script & gt; & Lt; Mx: tabbar id = "click some tabs" item = "click (event)" & gt; & Lt; Mx: dataProvider & gt; & Lt; Mx: string & gt; Foo & lt; / Mx: string & gt; & Lt; Mx: string & gt; Bar & lt; / Mx: string & gt; & Lt; Mx: string & gt; Hail & lt; / Mx: string & gt; & Lt; Mx: string & gt; Bam & lt; / Mx: string & gt; & Lt; / Mx: dataProvider & gt; & Lt; / Mx: TabBar>  

Comments

Popular posts from this blog

python - Overriding the save method in Django ModelForm -

html - CSS autoheight, but fit content to height of div -

qt - How to prevent QAudioInput from automatically boosting the master volume to 100%? -