You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So I've got some views that I want to move around in response to user interaction. To position them I have multiple constraints with different priorities - I can turn one or more constraints off and since there are still other constraints available the view (or whatever) moves to the new location. So normally I would do something like this:
So I've got some views that I want to move around in response to user interaction. To position them I have multiple constraints with different priorities - I can turn one or more constraints off and since there are still other constraints available the view (or whatever) moves to the new location. So normally I would do something like this:
self.settingsBottomConstraint.isActive = false
UIView.animate(withDuration: 0.5, delay: 0, options: [.curveEaseInOut], animations: {
self.brainView.layoutIfNeeded()
}, completion: nil)
How can I accomplish that using Spring? I've tried everything I can think of - it doesn't animate, just turns off the constraint without animation.
Two no good least weird looking things I've tried that doesn't work (I've tried many more):
self.settingsBottomConstraint.isActive = false
self.brainView.animateNext {
self.brainView.layoutIfNeeded()
}
or
self.brainView.animateNext {
self.settingsBottomConstraint.isActive = false
}
Help?! Surely I'm just doing it wrong?
The text was updated successfully, but these errors were encountered: