I am using Fusuma cocoal pod framework. However, I found that they have an Objective-C protocol even thought the whole project was written in Swift.
@objc public protocol FusumaDelegate: class {
func fusumaImageSelected(image: UIImage)
optional func fusumaDismissedWithImage(image: UIImage)
func fusumaVideoCompleted(withFileURL fileURL: NSURL)
func fusumaCameraRollUnauthorized()
optional func fusumaClosed()
}
I want to add another function in the protocol. However, I am getting this warning
Method cannot be a member of an @objc protocol because the type of the parameter cannot be represented in objective-C
I am thinking about removing the @objc in front of the protocol but then it says I have to remove optional func. I don't mind changing them to just normal func, however, I want to find out what should I be aware of if I remove @objc
The function that I am trying to add is another delegate function for the previous VC. I have 3 VCs in this case. The 2nd one which is this one grabs the data from 3rd VC after it was dismissed. Then I want to add the following delegate function to allow VC1 to start uploading the data
extension FusumaViewController: VC3Delegate {
func readyToUploadPost(postUpload: PostUpload) {
delegate_?.readyToUploadPost_Fusuma(postUpload)
}