2017-01-28 18 views
0

我有一个包含容器视图的视图控制器。此容器视图用于显示UIPageViewController及其各种页面。 包含容器视图的视图在页面顶部还包含一个导航栏 - 其中包含页面控件项。swift 3触发容器视图内容更新

这是安排:Screenshot

当它运行时,我可以在绿色和蓝色视图控制器之间滑动,和导航栏不移动。如何更新页面控件以显示我所在的页面?

+0

请添加您当前的代码 – muescha

+0

参阅本教程https://spin.atomicobject.com/2015/12/23/swift-uipageviewcontroller-tutorial/ – karthikeyan

回答

0

您应该使用UIPageViewControllerDataSource

func presentationCount(for: UIPageViewController) 
func presentationIndex(for: UIPageViewController)