2016-09-23 36 views
-2

我试图在单个视图中显示两个视图控制器。如何在单个视图中显示两个视图控制器?

我当前视图控制器类如下所示:

import UIKit 

class ViewController: UIViewController { 

override func viewDidLoad() { 
    super.viewDidLoad() 
    // Do any additional setup after loading the view, typically from a nib. 
} 

override func didReceiveMemoryWarning() { 
    super.didReceiveMemoryWarning() 
    // Dispose of any resources that can be recreated. 
}} 

我想要做什么:

+0

不使用赛格瑞 –

+0

请出示您的代码试图 –

+0

我不知道我应该使用 –

回答

0

集装箱意见应该可以帮助您与您的应用程序。

https://developer.apple.com/library/content/featuredarticles/ViewControllerPGforiPhoneOS/ImplementingaContainerViewController.html

“容器视图控制器将来自多个视图控制器的内容组合成一个单一的用户界面的方法。”

+0

[这里有一个体面的YouTube链接,教程](HTTPS什么命令:// www.youtube.com/watch?v=xIdgtfdoTEg) –

+0

tanQ Noah G .... –

+0

是的,这是正确的 –

相关问题