Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TIMOB-25919] Android: Always fire OptionDialog 'click' event #9979

Merged
merged 3 commits into from Apr 18, 2018

Conversation

garymathews
Copy link
Contributor

@garymathews garymathews commented Apr 2, 2018

  • Always fire Titanium.UI.OptionDialog click event, even when cancel is clicked
TEST CASE
var win = TI.UI.createWindow({ backgroundColor: 'gray' }),
    optionDialog = Ti.UI.createOptionDialog({
        title: 'SELECT',
        cancel: 2,
        options: [
          'OPTION #1',
          'OPTION #2',
          'CANCEL'
        ]
    });

optionDialog.addEventListener('click', function (e) {
    alert('CLICKED INDEX ' + e.index);
});

win.addEventListener('postlayout', function () {
    optionDialog.show();
});

win.open();

JIRA Ticket

@build
Copy link
Contributor

build commented Apr 2, 2018

Messages
📖

👍 Hey!, You deleted more code than you added. That's awesome!

📖

💾 Here's the generated SDK zipfile.

Generated by 🚫 dangerJS

Copy link
Contributor

@jquick-axway jquick-axway left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CR: Pass

@jquick-axway
Copy link
Contributor

I've verified that this change makes it match iOS' behavior.

@build build added the android label Apr 9, 2018
@lokeshchdhry
Copy link
Contributor

FR Passed.

click event is always fired when clicked on cancel or if clicked outside the options dialog.

Studio Ver: 5.1.0.201804161553
SDK Ver: 7.2.0 local build
OS Ver: 10.13.4
Xcode Ver: Xcode 9.3
Appc NPM: 4.2.13-2
Appc CLI: 7.0.3-master.39
Daemon Ver: 1.1.1
Ti CLI Ver: 5.1.0
Alloy Ver: 1.12.0
Node Ver: 8.9.1
NPM Ver: 5.5.1
Java Ver: 10
Devices: ⇨ google Nexus 5 --- Android 6.0.1
⇨ google Nexus 6P --- Android 8.0.0

@lokeshchdhry lokeshchdhry merged commit c88eea8 into tidev:master Apr 18, 2018
@sgtcoolguy sgtcoolguy modified the milestones: 7.2.0, 7.3.0 May 16, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants