Hide counter dots of UIPageViewController on last page

廉价感情. 提交于 2019-12-11 11:00:52

问题


I'm making a first tour view with a PageViewController, showing the counter dots at the bottom of the view.

How can I

  1. Hide the dots only in the last page ? and
  2. Adjust the height of the view to fit the full screen?

My last page will be the log in view of my app.

Thanks.


回答1:


You can use UIPageControl and hide it when you reach at last page. You can detect last page view delegate methods. You can find if current page is last page in this delegate method

- (void)pageViewController:(UIPageViewController *)pageViewController didFinishAnimating:(BOOL)finished previousViewControllers:(NSArray *)previousViewControllers transitionCompleted:(BOOL)completed{

 }


来源:https://stackoverflow.com/questions/32016338/hide-counter-dots-of-uipageviewcontroller-on-last-page

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!