Hi, in my android app i need to open 2 windows, but when i open the second window like i do in iOs, the old window still remains in foreground! this is my code:
var win= Ti.UI.createWindow({ }); var button = Ti.UI.createButton({ top:'auto', bottom:'auto', left:'auto', right:'auto' }); bottone_aggiungi.addEventListener("click",function(e){ var new_win= Ti.UI.createWindow({ }); new_win.open(); win.open();When i click on the button the new window opens but the old window still remains in foreground and if i do new_win.close(); i close everything! Does somebody know why?thanks
2 Answers
Accepted Answer
Hi Raffaele,
Try to open in modal window.
var new_win= Ti.UI.createWindow({ }); new_win.open({ modal : true });
in win Eventlistener you have to open new_win.open() and close the current window i.e win.close() and vice - versa .
Your Answer
Think you can help? Login to answer this question!