Xcode选项卡式应用程序-添加新的选项卡视图 [英] Xcode Tabbed Application - Adding New Tab view

查看:136
本文介绍了Xcode选项卡式应用程序-添加新的选项卡视图的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用Xcode 4.2.我开始使用选项卡式应用程序工作,现在我想在应用程序的故事板上添加第3和第4个选项卡式故事板.如何添加? 我尝试使用它,但是我不能. :(我没有很好的教程.

I'm working with Xcode 4.2. I started to work with Tabbed Application and now I want to add 3rd and 4th Tabbed to story board on my application. How Can I add it? I try to use it but I cannot. :( I didn't get good tutorials for it.

有人知道怎么做吗?

我通过了此链接,但我需要在第一个视图中再添加2个选项卡式视图.

I went through this link, but I need to add 2 more Tabbed views to first view.

更新:

只需创建一个标记的应用程序,他们就会尝试添加一个或两个以上的标签视图.我还在尝试.但是我不能.

Just go and create Tabbed Application and they try to add one or two more tab view. I'm still trying it. But I can't.

推荐答案

只需将两个视图控制器添加到您的项目中,然后控制从选项卡栏控制器向视图控制器的拖动以对其进行监视.列表弹出时,请确保选择"Relationship-viewControllers".标签将自动添加.

Just add two more view controllers to your project, and then control drag from the tab bar controller to the view controllers to make segues to them. Make sure you select "Relationship-viewControllers" when the list pops up. Tabs will automatically be added.

您必须转到菜单,然后单击新建文件",然后单击"Objective-C"类,最后确保选择UIViewController子类.命名它,然后它将添加.h和.m文件.现在,在情节提要中,确保将每个选项卡的类更改为文件名.就是这样.

You have to go to the menu and click on "New File", then Objective-C class, and finally make sure to select UIViewController subclass. Name it and then it will add the .h and .m files. Now in your storyboard make sure to change the class of each tab to the name of your file. That's it.

这篇关于Xcode选项卡式应用程序-添加新的选项卡视图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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