Commit 99c20e7b by Orkhan Alikhanov

Fixed UITabBarController had userinteraction enabled during transition

transitioningViewController is either UITabBarController or
UINavigationController. If you enable Motion on a UITabBarController
and tap multiple times on the tabBar item, Motion will restart transition on
each tap unless the transition is over. We fix this by disabling interaction
on UITabBarController while transition is happening.
parent 358c2a4c
......@@ -124,6 +124,7 @@ extension MotionTransition {
}
transitionContainer?.isUserInteractionEnabled = true
transitioningViewController?.view.isUserInteractionEnabled = true
completionCallback?(isFinishing)
......
......@@ -135,6 +135,7 @@ fileprivate extension MotionTransition {
/// Prepares the transition container.
func prepareTransitionContainer() {
transitioningViewController?.view.isUserInteractionEnabled = isUserInteractionEnabled
transitionContainer?.isUserInteractionEnabled = isUserInteractionEnabled
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment