-
Notifications
You must be signed in to change notification settings - Fork 128
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Completion closure never called when animating showing/hiding #70
Comments
A workaround is to use a CATransaction:
|
I’ve encountered this problem too, nice workaround! Is the completion block never called in your experience? In my case it works the first time, but not on subsequent calls. I suspect the cause is this line in the code of UIView.setAnimationDelegate(self) It’s just a guess, but I think UIView implements the completion callback by setting some internal object as the delegate of the animation. Which then brings the question, does calling EDIT: it seems issue #50 is referring to the same problem, this definitely needs to be looked into. Unfortunately it’s going to be a while before I’m able to do it myself, but I will if it hasn’t been fixed yet. |
…ixing tomvanzummeren#70 (Completion closure never called when animating showing/hiding) and tomvanzummeren#50 (Setting TZStackView to hidden inside animateAlongsideCoordinator's animation block causes strange behavior)
Fixed in #72 |
…xing tomvanzummeren#70 (Completion closure never called when animating showing/hiding) and tomvanzummeren#50 (Setting TZStackView to hidden inside animateAlongsideCoordinator's animation block causes strange behavior)
UIView.animateWithDuration(0.5, animations: {
subview.hidden = false
}, completion: { finished in
// never called when changing hidden property of a subview of TZStackView
})
The text was updated successfully, but these errors were encountered: