I'm studing Codestrong 2012 app and trying to make it work on SDK 3.1.3.
I thought xml views should have unique id's, but I've found this:
//main.xml
<Alloy>
<View id="container">
<View id="content"> </View>
<!-- ... -->
</View>
</Alloy>
and
//drawer.xml
<Alloy>
<View id="container">
<!-- ... -->
</View>
</Alloy>
then, mains.js controller have a piece of code that does:
var d = Alloy.createController('drawer');
// ...
$.container.add(d.getView());
How come drawer.xml have a view with id=container added within main.xml which also have a view with a id=container ?
Is this ok ?
how could you access second #container form main controller?