Last active
November 10, 2017 07:38
-
-
Save pgpt10/c45aa3fdeb1031ce14a893f2b4467353 to your computer and use it in GitHub Desktop.
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 collectionView(_ collectionView: UICollectionView, itemsForBeginning session: UIDragSession, at indexPath: IndexPath) -> [UIDragItem] | |
{ | |
let item = self.items[indexPath.row] | |
let itemProvider = NSItemProvider(object: item as NSString) | |
let dragItem = UIDragItem(itemProvider: itemProvider) | |
dragItem.localObject = item | |
return [dragItem] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment