Created
June 21, 2020 15:46
-
-
Save sgl0v/e4c70e513d6403a362b8a9242ccc5203 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
private func createTransitionAnimators(with duration: TimeInterval) -> [UIViewPropertyAnimator] { | |
switch state { | |
case .open: | |
return [ | |
openPlayerAnimator(with: duration), | |
fadeInPlayerAnimator(with: duration), | |
fadeOutMiniPlayerAnimator(with: duration) | |
] | |
case .closed: | |
return [ | |
closePlayerAnimator(with: duration), | |
fadeOutPlayerAnimator(with: duration), | |
fadeInMiniPlayerAnimator(with: duration) | |
] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment