Krisiacik / ImageViewer

An image viewer à la Twitter
MIT License
2.53k stars 385 forks source link

Need hooks for delete confirmation #235

Open robertcrabtree opened 4 years ago

robertcrabtree commented 4 years ago

It would be nice if there was a way to prompt the user for delete confirmation before an image is deleted. I was thinking we could add a separate delegate method called shouldRemoveGalleryItem so we could make sure that the user wants to delete. I've created a PR here.

Another option is to make GalleryImageViewController.deleteItem a public method so we can supply our own delete button in the header or footer and call the deleteItem method ourselves. I didn't create a PR for this option but let me know what you think.