Skip to content

Instantly share code, notes, and snippets.

@rblalock
Created January 19, 2011 02:15
Show Gist options
  • Save rblalock/785567 to your computer and use it in GitHub Desktop.
Save rblalock/785567 to your computer and use it in GitHub Desktop.
// Include framework files
Ti.include('system/core.js');
// Set app preferences
var App = new TiGantry(
'0.1', // App version
'Zergling', // App version name
'tweetrdone', // Name of app
'app', // Location of app directory
'controllers', // Location of controllers directory
'layouts' // Location of layouts directory
);
// Set the theme
App.setTheme('default');
// Include app files
Ti.include(
'app/plugins/global.js',
'app/helpers/ui.js',
'app/helpers/events.js',
'app/components/navbar.js'
);
// Object that stores all the app windows
var APP_WINDOWS = {
main: Ti.UI.createWindow(TiGantry.Styles.mainWindow) // Main window
};
// Create the main nav bar instance (This is a custom view implementation)
//var MAIN_NAVBAR = new TiGantry.Components.Navbar(APP_WINDOWS.main);
// Set the main window data title
APP_WINDOWS.main.title = 'Tweet\'r Done';
// ----- Build the tabs ----- //
var APP_TABS = Ti.UI.createTabGroup();
var window_tab = Ti.UI.createTab({
title: 'Tweet\'r Done',
window: APP_WINDOWS.main
});
// Load the default controller
var list = new App.Controller('List');
list.execute('init', true);
// Add the tabs to the window
APP_TABS.addTab(window_tab);
APP_TABS.open();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment