Snapchat样式的多个ViewController访问 [英] Snapchat style multiple ViewController access

查看:55
本文介绍了Snapchat样式的多个ViewController访问的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Snapchat中,您可以向左或向右滑动并访问从摄像头到桌面视图的完全不同的UIViewController.

In Snapchat, you can swipe left or right and access an entirely different UIViewController, from the camera to tableviews.

所有的ViewController似乎都处于活动状态并被保留,因此它们之间的切换是平稳的,不需要任何过渡.

It appears that all viewControllers are kept live and retained, so switching between them is smooth and doesn't require any kind of transition.

有人知道这是如何实现的,或者可以为我指明正确的方向吗?谢谢

Does anyone know how this is achieved or can point me in the right direction? Thanks

推荐答案

这是通过自定义容器视图控制器完成的.该容器很可能是带有分页的滚动视图.请参阅创建自定义容器视图控制器.

It's done with a custom container view controller. The container is most likely a scroll view with paging. See Creating Custom Container View Controllers.

实际上,您不必构建自定义容器视图控制器即可为您执行此操作. iOS已经具有UIPageViewController.

You actually don't have to build a custom container view controller to do this for you. iOS already has UIPageViewController.

这篇关于Snapchat样式的多个ViewController访问的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆