Parent tabbar containers not being re-sized

Hi Alexandra,

I’ve found that when I put an autoresize on a nested (child) tabbar, when I switch from a smaller tab in the child tabbar to a larger one (height-wise), if the larger tab is bigger than the parent tabbar container, although the child tab has resized, the parent container hasn’t and so the bottom part of the child tab is cut off by the parent container.

Is there a way to get the parent tabbar to resize automatically, if a child tabbar has resized to be larger than it’s parent tabbar?



autoSize doesn’t change the size of the parent container.

If autosize is enabled for both child and parent tabbars, you may do the following:

childTabbar.attachEvent("onSelect",function(id){ window.setTimeout(function(){ parentTabbar.cells(parentTabId).autoSize() },1) return true })

Where parentTabId is the id of the tab when child tabbar is initialized.

Is there a solution for doing this same thing when the tabbar has been initialized from HTML markup?

Yes, there is. You may set oninit attribute that sets function called after tabbar initialization::


After tabbar initialization its object is available by the name of its html container. a_tabbar in this case:

I thought this was worth mentioning, but when the page loads, this event does not seem to fire. I can only get it to work when clicking on each tab.

“oninit” function is called after Tabbar is initialized. It means that a tab is already selected.

Try to set onbeforeinit attribute instead of oninit. In this case, the tab will be selected after onSelect handler is set: