How to remove greying effect (fade animation) when performing push and pop while using CATransition?

733 views Asked by At

Currently the transition of pushing and popping a UIViewController onto and off a UINavigationController stack looks like this

For brevity I have posted the code being used on both UIViewControllers is as follows:

    let transition = CATransition()
    transition.duration = 2
    transition.timingFunction = CAMediaTimingFunction(name: kCAMediaTimingFunctionEaseInEaseOut)
    transition.type = kCATransitionPush
    transition.subtype = kCATransitionFromTop

    navigationController?.view.layer.add(transition, forKey: kCATransition)
    navigationController?.popViewController(animated: false)

My question is how to remove the greying effect it has on the View being pushed off the screen and the same greying effect on the View being pushed on to the screen. Can this greying effect be eliminated. If so, could you please guide me how it can be done? Thank you.

0

There are 0 answers