I decided to throw in a small post about what I think is a common issue with a not-so-straightforward solution. If you are using a TabNavigator with some children containers like a Panel, Canvas or a ViewStack in Flex 3 and you want to disable the children completely so as to remove the tab itself then setting just the visible/enabled and/or the includeInLayout property to false for the specific container will not do the job. The trick is to access the tab from the TabNavigator by getTabAt() and setting it’s visible to false. So, in the code you would do:
tabNav.getTabAt(1).visible = false;
Where tabNav is the id of the TabNavigator.
View source is enabled in the following example.
The live example iFrame is temporarily disabled for this post. You can still access it here.
Download the source code here
0 comments ↓
There are no comments yet...Kick things off by filling out the form below.
Leave a Comment