Problem
When an optionDialog is being displayed, and the hardware back button is pressed, optionDialog's index contains the strange value of
-268435457
. I feel the event should not be returned.
Test case
* run code below
* click on the button so that optionDialog shows
* hit the hardware back-button. You'll see that this triggers dialog's click event and displays the index value.
var win = Ti.UI.createWindow({
fullscreen: true,
backgroundColor: '#000'
});
var button = Ti.UI.createButton({
title: 'Open dialog'
});
button.addEventListener('click', function() {
var dialog = Ti.UI.createOptionDialog({
options: ['Option 1', 'Option 2', 'Option 3'],
title: 'Options'
});
dialog.addEventListener('click', function(e) {
Ti.API.info('optionDialog click event!');
Ti.API.info('optionDialog index value = ' + e.index);
});
dialog.show();
});
win.add(button);
win.open();
Results
588 TiAPI I optionDialog click event!
588 TiAPI I optionDialog index value = -268435457
Vinothbabu You are fortunate that this ticket is almost identical to Ivan's, because it would not have been accepted otherwise. This is because it contained almost none of the necessary information. Please ensure that you read [JIRA Ticket Checklist](https://wiki.appcelerator.org/display/guides/How+to+Submit+a+Bug+Report) before raising any more tickets. Now that I have completed the information with the help of Ivan's ticket, I will escalate this ticket to our engineering team. Thank you for your understanding.
Closing ticket due to time passed, lack of progress for a number of years and there are linked issues that have more activity. Please open a new ticket if there are any problems.