[TIMOB-92] Support ability to set active tab
| GitHub Issue | n/a |
|---|---|
| Type | Bug |
| Priority | Medium |
| Status | Closed |
| Resolution | Fixed |
| Resolution Date | 2011-04-17T01:51:57.000+0000 |
| Affected Version/s | n/a |
| Fix Version/s | Release 0.6.2 |
| Components | iOS |
| Labels | n/a |
| Reporter | Nolan Wright |
| Assignee | Nolan Wright |
| Created | 2011-04-15T02:23:34.000+0000 |
| Updated | 2011-04-17T01:51:57.000+0000 |
Description
Support the ability to set the active tab programatically (both Android and iPhone)
1) get the tabs
Method 1:
var tabs = Titanium.UI.getTabs();
Titanium.UI.setActiveTab(tabs[0]);
Method 2:
var tab = Titanium.UI.getTabByName('Views');
Titanium.UI.setActiveTab(tab);
The name of the tab is the field specified in the tiapp.xml file
No comments