开发者

Loop a UIScrollviw with ViewControllers

I'm trying to create a UIScrollView with loop that contains 开发者_如何学Goa collection of ViewControllers. The answer to this question here shows the code that is the basis for what I'm trying to do. It uses images instead of viewControllers.

I've managed to get the all the viewControllers loaded (4) and displaying but the first view which is a duplicate of the last viewController is blank. I've tried creating a copy of this viewController and adding it to the array but this messes up the transition / count. Any suggestions?


Solved.

Simply add a copy of the viewController (copyWithZone) to the array then create another copy of the two viewControllers for the first and last frame. I had done this only for the first and last frames not the array.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜