Search code examples
titaniumtitanium-mobileappcelerator

appcelerator hide actionBar from tabgroup


I want to hide ActionBar from tabGroup in appcelerator titanium android. When we create new project in appcelerator it by defaults has a tabbar and an actionbar on it. I want to remove that actionBar and only want to have tabs in my tab group I tried many codes one of them is as below

tabGroup.addEventListener("open", function() {
    var actionBar = tabGroup.getActivity().actionBar;
    if (actionBar) {
        actionBar.hide();
    }
});

But this code sample also hides the tabs of my tabgroup. Please help me. Thanks in advance.


Solution

  • Unfortunately that is not possible. Titanium mobile implements TabGroup and Tabs using ActionBar.Tab functionality Source code of Titanium TabGroup

    So if you hide the ActionBar, you will hide the Tabs as well :)