Closed madhavgharmalkar closed 5 months ago
I was able to find a solution, and I'm sharing what I did to get it to work here. I am using Tuist + SwiftUI.
For some reason, it seems that when using CropViewController (the swift version), Xcode is able to find the header declaration for UIImage+CropView.h
but unable to find the implementation for it. My solution was to use the ObjC VC TOCropVuewController
and include the headers via settings.
settings: .settings(
base: [
"HEADER_SEARCH_PATHS": [
"$(SRCROOT)/Tuist/.build/checkouts/TOCropViewController/Objective-C/TOCropViewController/include/TOCropViewController"
]
]
)
Describe the bug A clear and concise description of what the bug is.
I am initializing a
CropViewController
with a UIImage. However when I press "done" in the presented ViewController I'm receiving the following error. I do not receive this error when the delegate is nil."-[UIImage croppedImageWithFrame:angle:circularClip:]: unrecognized selector sent to instance 0x600003002e20"
To Reproduce Steps to reproduce the behavior:
Expected behavior A clear and concise description of what you expected to happen.
I should expect the delegate to be called.
Screenshots If applicable, add screenshots to help explain your problem.
iOS Device:
2.7.3
Additional context
Given an
UIImage image
, I am able to seeimage.croppedImage(withFrame: , angle: , circularClip:)