Reputation: 157
So i have file1 which is:
<Alloy>
<Window class="container">
<View class='game1' id = 'game1'></View>
<View class='game2'></View>
<View class='game3'></View>
<View class='game4'></View>
<View class='game5'></View>
<View class='game6'></View>
<View class='game7'></View>
<View class='game8'></View>
<View class='game9'></View>
</Window>
</Alloy>
and file 2 is
<Alloy>
<View>
<View class='game1'></View>
<View class='game2'></View>
<View class='game3'></View>
<View class='game4'></View>
<View class='game5'></View>
<View class='game6'></View>
<View class='game7'></View>
<View class='game8'></View>
<View class='game9'></View>
</View>
</Alloy>
i do:
var GAME1 = Alloy.createController('file2');
$.game1.add(GAME1);
this works in iphone if file 2 was a window but android does not support windows in a window and crashes. this way does not seem to work either for android. the end goal is to have a 3x3 board with another 3x3 board but would need to be in 2 different files.
Upvotes: 0
Views: 1723
Reputation: 33345
first off try this
var GAME1 = Alloy.createController('file2');
$.game1.add(GAME1.getView());
Upvotes: 2