Last active
January 2, 2018 13:15
-
-
Save paul1893/cbb8f23252dce73f4a491b71c509ce22 to your computer and use it in GitHub Desktop.
drag and drop ios 11 octo article
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| func dropInteraction(_ interaction: UIDropInteraction, canHandle session: UIDropSession) -> Bool { | |
| let identifiers = [kUTTypeImage as String] // Can be very specific [kUTTypeImagePNG as String] (Only PNG) | |
| return session.hasItemsConforming(toTypeIdentifiers: identifiers) && session.items.count == 1 | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment