plugins icon indicating copy to clipboard operation
plugins copied to clipboard

Update index.ios.ts to remove callback on cancel of DateTimePicker dialog.

Open mrwrighty opened this issue 3 years ago • 5 comments

Removed callback(null) for cancelAction in iOS. If left in this results in datePickerClosed event being called.

mrwrighty avatar May 24 '22 15:05 mrwrighty

Thank you for your pull request and welcome to our community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. In order for us to review and merge your code, please sign the CLA at https://www.nativescript.org/cla. CLA has not been signed by users: @mrwrighty. After signing the CLA, you can ask me to recheck this PR by posting @cla-bot check as a comment to the PR.

cla-bot[bot] avatar May 24 '22 15:05 cla-bot[bot]

@cla-bot check

mrwrighty avatar May 24 '22 15:05 mrwrighty

The cla-bot has been summoned, and re-checked this pull request!

cla-bot[bot] avatar May 24 '22 15:05 cla-bot[bot]

Isn't a cancel a close though? Just wondering without anything to notify when canceled would leave out a way to respond to when the datepicker is no longer on screen, which you may want if doing other ui or data reactions when showing the datepicker. Idk?

NathanWalker avatar May 28 '22 16:05 NathanWalker

Cancel is a close but still calls onDateChanged even though callback(null) is used. By removing the callback(null) the datetimepicker just closes with no event.

mrwrighty avatar May 28 '22 16:05 mrwrighty