Posts

Post not yet marked as solved
0 Replies
429 Views
I use UIImagePickerController to choose image from photo library, set it's allowsEditing to YES, and want to do something in navigationController willShowViewController method such as add a circle crop view. Here are the code:- (void) imageItemClicked { UIImagePickerController *vc = [[UIImagePickerController alloc] init]; vc.sourceType = UIImagePickerControllerSourceTypePhotoLibrary; vc.allowsEditing = YES; vc.delegate = self; [self presentViewController:vc animated:YES completion:nil]; } - (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary<uiimagepickercontrollerinfokey,id> *)info { [picker dismissViewControllerAnimated:YES completion:nil]; } - (void)navigationController:(UINavigationController *)navigationController willShowViewController:(UIViewController *)viewController animated:(BOOL)animated { NSLog(@"willShowViewController"); }But the navigationController 'willShowViewController' method did not get called when I choose image from photo library. Such as select a photo in 'Photos' screen and select a photo in 'All Photos' screen. Why?It works well in iOS 12 and iOS 13 beta3. It not work in iOS 13 beta5.
Posted
by Eva Zhang.
Last updated
.