I would like to implement a view sliding effect, similar to the view animation presented by presentModalViewController, but the view is only shown to close half the screen.
I went like this:
1) Right before the view will be displayed and displayed, addSubview is a child view. Place it so that it does not look in the beginning.
2) Call the method on the subview view controller to execute the Core Animation code to enter it.
Doing the above does not seem to work (nothing happens - the view just appears in its original location). Adding a view ahead of schedule in viewDidLoad will also not work. Ideally, I would like the code to have the same requirement as presentModalViewController - which requires you to instantiate the view controller at the point where you need to enable the view and animate it.
It would be nice if you could specify a pointer or code to animate the view in / out.
source
share