Created
February 17, 2014 15:21
-
-
Save davidecassenti/9052533 to your computer and use it in GitHub Desktop.
Appcelerator Titanium | Alloy | Put 2 NavigationWindow inside TabGroup
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 openMaster() { | |
var win = Ti.UI.createWindow({ | |
title: "Master 2", | |
backgroundColor: 'red' | |
}); | |
$.master_win.openWindow(win); | |
} | |
function openDetail() { | |
var win = Ti.UI.createWindow({ | |
title: "Detail 2", | |
backgroundColor: 'green' | |
}); | |
$.detail_win.openWindow(win); | |
} | |
$.index.open(); |
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
"Window": { | |
backgroundColor:"white" | |
}, | |
"Label": { | |
color: "#000" | |
} |
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
<Alloy> | |
<TabGroup> | |
<Tab title="Tab 1" icon="KS_nav_ui.png"> | |
<SplitWindow id="splitWin" platform="ios" formFactor="tablet"> | |
<NavigationWindow id="master_win"> | |
<Window title="Master 1"> | |
<Label onClick="openMaster">Master</Label> | |
</Window> | |
</NavigationWindow> | |
<NavigationWindow id="detail_win"> | |
<Window title="Detail 1"> | |
<Label onClick="openDetail">Detail</Label> | |
</Window> | |
</NavigationWindow> | |
</SplitWindow> | |
</Tab> | |
<Tab title="Tab 2" icon="KS_nav_views.png"> | |
<Window title="Tab 2"> | |
<Label>I am Window 2</Label> | |
</Window> | |
</Tab> | |
</TabGroup> | |
</Alloy> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment