Description
Expected behavior
I'd like the ability to get a callback, either through a closure or a delegate method when the user requests to close the view controller. This better matches Apple's own API's (e.g. UIImagePickerControllerDelegate
) and allows the code that presented SimpleImageViewer
to also be in charge of dismissing it.
Actual behavior
Currently, there is no way to control this. SimpleImageViewer
dismisses itself when the X button is tapped by the user.
Discussion
I wanted to know as the library maintainer whether you would like a feature like this added to the library or whether you would be OK with making small changes to SimpleImageViewer
to make it subclassable.
Right now, I've modified it to make it subclassable to add this feature. I really want to submit a pull request for either solution you prefer (hopefully you like one of them 😇). But I wanted to get the opinion of someone that maintains the project before blindly submitting a PR 😀.
Thanks
And a big thanks for the library. Small UI's like this are so helpful to iOS development where even such a "simple" task as showing an image full screen can take so long when doing them from scratch.