Last active
December 6, 2016 02:34
-
-
Save rchatham/ed620ab0136ce8ce45e5ae7ee6837abc to your computer and use it in GitHub Desktop.
Performing Queued animations
This file contains 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 perform() { | |
guard let animation = animations.dequeue else { return } | |
UIView.animate(withDuration: animation.0, animations: animation.1) { success in | |
perform() | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment