I am presenting a model view with animation. As a default it comes from bottom to top. How can I make the animation to go from left to right? I know I could use a navigation controller. But actually the presenting view does not need a navigation bar and also the modally presented view does not need a navigation bar. Still I want a transition from left to right.
You can animate from right to left while presenting a view controller by using the following code
CATransition *transition = [CATransition animation];
transition.duration = 0.4;
transition.timingFunction = [CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseInEaseOut];
transition.type = kCATransitionPush;
transition.subtype = kCATransitionFromRight;
[self.view.window.layer addAnimation:transition forKey:nil];
[self presentViewController:localitiesView animated:NO completion:nil];