Click eventlistener causes crash when clicking multiple views at once
I'm currently working on an iPad app with multiple views within a window that when clicked will open up a new window within a navgroup. The problem I'm having is that if I click 2 or more of those views on the device at almost the same time (multitouch) it is crashing hard out of the app.
Is there any way I can stop it from catching those other click events – or ignore them? I've tried setting a boolean flag, moving the click event to the parent view, but nothing seems to help.
Code looks something like:
function showNext(e) {
if(!alreadyOpened) { // this doesn't seem to work
navGroup.open(Details.mainWindow,{animated:true});
alreadyOpened = true;
}
}
myView.addEventListener('click', showNext);
Thanks for any and all help!