Created
July 2, 2012 21:23
-
-
Save pegli/3035796 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function ApplicationTabGroup(Window) { | |
var MusicWindow = require('ui/handheld/MusicWindow'), | |
VideosWindow = require('ui/handheld/VideosWindow'), | |
SearchWindow = require('ui/handheld/SearchWindow'); | |
//create module instance | |
var self = Ti.UI.createTabGroup(); | |
//create app tabs | |
var win1 = new MusicWindow(L('music')), | |
win2 = new VideosWindow(L('videos')), | |
win3 = new SearchWindow(L('search')); | |
var tab1 = Ti.UI.createTab({ | |
title: L('home'), | |
icon: '/images/KS_nav_ui.png', | |
window: win1 | |
}); | |
win1.containingTab = tab1; | |
var tab2 = Ti.UI.createTab({ | |
title: L('settings'), | |
icon: '/images/KS_nav_views.png', | |
window: win2 | |
}); | |
win2.containingTab = tab2; | |
var tab3 = Ti.UI.createTab({ | |
title: L('settings'), | |
icon: '/images/KS_nav_views.png', | |
window: win3 | |
}); | |
win3.containingTab = tab3; | |
self.addTab(tab1); | |
self.addTab(tab2); | |
self.addTab(tab3); | |
return self; | |
}; | |
module.exports = ApplicationTabGroup; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment