Question

I'm looking for a way to implementing a page curl transition between views. Basically, I've got a view controller in which I have a book. I have to implement the opening of the book and transition between pages.

I know about the existance of UIPageViewController and it's page curl transition style and I'm looking to implementing something like that, only applied on views. (On my view controller I've got other views and buttons, alongside the book.)

I should be able to move the page back and forth with my finger and to able to let it go.

Était-ce utile?

La solution

1) Create an array of controllers for all the views that you want to transition.

NSArray *array = [NSArray arrayWithObjects:vc1, vc2, vc3,...];

2) Then add the view controller array to your UIPageViewController object.

[yourPageController setViewControllers:array direction:UIPageViewControllerNavigationDirectionForward animated:YES completion:nil];

For more reference- http://www.techotopia.com/index.php/An_Example_iOS_5_iPhone_UIPageViewController_Application

Please read the Apple's documentation for other details

http://developer.apple.com/library/ios/#documentation/uikit/reference/UIPageViewControllerClassReferenceClassRef/UIPageViewControllerClassReference.html

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top