UIPageViewController in iOS6

前端 未结 5 1942
野趣味
野趣味 2020-12-24 07:59

In iOS6 in the methods viewControllerAfterViewController and viewControllerBeforeViewController if I return nil (for block the page navigat

5条回答
  •  -上瘾入骨i
    2020-12-24 08:24

    I had the issue with UIPageViewController crashing with iOS6 with the same error ('The number of view controllers provided (0) doesn't match the number required (1) for the requested transition').

    None of the above solutions worked for me but I eventually found that moving the following line from viewDidLoad to viewDidAppear fixed it.

    self.view.gestureRecognizers = self.pageViewController.gestureRecognizers;
    

提交回复
热议问题