Created
July 26, 2018 13:36
-
-
Save CibelePaulinoAndrade/64b62d85700b12b048cb99b0994b5089 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
//Habilitando interações | |
dragImageView.isUserInteractionEnabled = true | |
dropImageView.isUserInteractionEnabled = true | |
dragTextView.isUserInteractionEnabled = true | |
dropTextView.isUserInteractionEnabled = true | |
//Adicionando interações de Drag | |
let dragImageInteraction = UIDragInteraction(delegate: self) | |
let dragTextInteraction = UIDragInteraction(delegate: self) | |
dragImageView.addInteraction(dragImageInteraction) | |
dragTextView.addInteraction(dragTextInteraction) | |
//Adicionando interações de Drop | |
let dropImageInteraction = UIDropInteraction(delegate: self) | |
let dropTextInteraction = UIDropInteraction(delegate: self) | |
dropImageView.addInteraction(dropImageInteraction) | |
dropTextView.addInteraction(dropTextInteraction) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment