I am struggling with a problem. I am capturing a video, and i had put an UIImageView with an UIImage in it as the UIImagePicker CameraOverLay. So when the user starts the c
For Swift 4, it is:
NotificationCenter.default.addObserver(forName: NSNotification.Name(rawValue: "_UIImagePickerControllerUserDidCaptureItem"), object:nil, queue:nil, using: { note in
print("camera did capture")
})
NotificationCenter.default.addObserver(forName: NSNotification.Name(rawValue: "_UIImagePickerControllerUserDidRejectItem"), object:nil, queue:nil, using: { note in
print("user pressed Retake")
})
Solved by signing up to NSNotificationCenter, and listening to @"_UIImagePickerControllerUserDidCaptureItem" and @"_UIImagePickerControllerUserDidRejectItem".