[TIMOB-27427] iOS 13: Natively presented modal windows are not dismissed properly
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | High |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2019-10-11T14:03:24.000+0000 |
Affected Version/s | Release 8.2.0 |
Fix Version/s | Release 8.2.1 |
Components | iOS |
Labels | engSchedule |
Reporter | Hans Knöchel |
Assignee | Vijay Singh |
Created | 2019-09-30T07:31:58.000+0000 |
Updated | 2020-10-05T08:37:00.000+0000 |
Description
When using iOS 13, native modal windows like the one from
Ti.Media.showCamera
are not presented correctly, causing the underlaying view controller to not be dismissed correctly.
var win = Ti.UI.createWindow();
var btn = Ti.UI.createButton({ title: 'Show camera' });
btn.addEventListener('click', () => {
Ti.Media.requestCameraPermissions(event => {
Ti.Media.showCamera({
success: () => {},
error: () => {},
cancel: () => {},
});
});
});
win.add(btn);
win.open();
This should be handled it 8.2.1!
Better test case:
[~hknoechel] 1. The first test case (mentioned in description) is working fine for me. 2. In second test case, as you are trying to open navigation window modally, default presentation style in iOS 13 will be page sheet. It looks when dismissing the camera controller it takes away the controller behind it. So better is use "forceModal" property. You can use "modalStyle" also if you want full screen. See updated example-
Sorry, but that's just the workaround to the breaking change. Please fix this properly in the SDK.
I'll check how it behaves if we open Camera on modally presented view controller in native iOS app.
PR(master) - https://github.com/appcelerator/titanium_mobile/pull/11256 PR(8_2_X) - https://github.com/appcelerator/titanium_mobile/pull/11257 Apart from test case mentioned in this ticket need to test following test cases from TIMOB-27169 1.
2.
FR passed. PR on master branch merged. Waiting for build to pass on 8_2_X branch.
This caused a regression where modal windows cannot be presented fullscreen anymore. See TIMOB-27453 for details.
Verified on latest build: 8.2.1.v20191010112656. Modal window dismissed correctly. Ticked closed. This ticked causes a regression, however, as indicated above.