Titanium Community Questions & Answer Archive

We felt that 6+ years of knowledge should not die so this is the Titanium Community Questions & Answer Archive

The "More . . " tab is showing up unbidden. How to get rid of it?

This happens on the iPhone (3GS, anyhow) but not on the emulator: The "More . . ." button appears at the right of the four tabs I've designed. It's not needed and I don't want it there – can I make it go away?

Thanks,

Mark

— asked November 28th 2010 by Mark Pemburn
  • iphone
  • more
  • tab
0 Comments

2 Answers

  • To check you have your tabs set up correctly, would it be possible to show us the code of your app.js file which creates your tabs, then I'm sure one of us might be able to help.

    — answered November 28th 2010 by Kosso
    permalink
    0 Comments
  • The tab setup is basically cribbed from the Kitchen Sink. I put it into a function 'cuz there are a couple of asynchronous processes that have to run before the opening window can be displayed. Here's the relevant portion:

    function launchApp(tzData) {
        var tabGroup = Titanium.UI.createTabGroup();
    
        //*** The 'Hours' window is the root
        var hoursWin = Titanium.UI.createWindow({  
            title: 'The Hours',
            url: 'main_windows/planetary_hours.js',
            backgroundColor: 'black',
            barColor: '#111',
             latitude: tzData.latitude,
             longitude: tzData.longitude,
             tzOffset: tzData.offset,
             currentDate: null
        });
        var hoursTab = Titanium.UI.createTab({  
            icon: './images/hours.png',
            title: 'Hours',
            window: hoursWin
        });
    
        //*** Set Location page
        var locWin = Titanium.UI.createWindow({  
            title: 'Set Location',
            url: 'main_windows/set_location.js',
            backgroundColor: 'black',
            barColor: '#111',
             latitude: tzData.latitude,
             longitude: tzData.longitude
        });
        var locationTab = Titanium.UI.createTab({  
            icon: './images/loc_change.png',
            title: 'Location',
            window: locWin
        });
    
        //*** Set Date page
        var dateWin = Titanium.UI.createWindow({  
            title: 'Set Date',
            url: 'main_windows/select_date.js',
            backgroundColor: '#fff',
            barColor: '#111'
        });
        var dateTab = Titanium.UI.createTab({  
            icon: './images/date_change.png',
            title: 'Date',
            window: dateWin
        });
    
        //*** Settings page
        var settingsWin = Titanium.UI.createWindow({  
            title: 'Settings',
            url: 'main_windows/settings.js',
            backgroundColor: '#fff',
            barColor: '#111'
        });
        var settingsTab = Titanium.UI.createTab({  
            icon: './images/settings.png',
            title: 'Settings',
            window: settingsWin
        });
    
        //*** Page selection tabs
        tabGroup.addTab(hoursTab);  
        tabGroup.addTab(locationTab);  
        tabGroup.addTab(dateTab);  
        tabGroup.addTab(settingsTab);  
    
        //*** Open the tab group
        tabGroup.open();
    }
    
    — answered November 28th 2010 by Mark Pemburn
    permalink
    0 Comments
The ownership of individual contributions to this community generated content is retained by the authors of their contributions.
All trademarks remain the property of the respective owner.