如何:标签栏控制器中的导航控制器 [英] How to : Navigation Controller in Tab Bar Controller

查看:136
本文介绍了如何:标签栏控制器中的导航控制器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用一个简单的iphone应用程序。该应用程序在第一个屏幕上有一个表格视图。如果用户单击该表视图上的项目,则应用程序将导航到第二个视图。第二个视图也有一个表格视图。如果用户点击此屏幕上的项目,我想显示一个新的xib,它有标签栏控制器。

I'm woking on a simple iphone application. The applicaton has a table view on first screen. If the user clicks on an item on that table view, application navigates to the second view. The second view has a table view, too. If the user clicks on an item on this screen, I want to show a new xib which has Tab Bar Controller.

实际上,我做到了。但是,问题是我看不到标签。标签显示在屏幕外部的底部。我该如何解决这个问题?

Actually, I did it. But, the problem is that I can't see the tabs. The tabs are shown at the bottom, outside of the screen. How can I solve this problem?

谢谢。

推荐答案

这里是一个我能够工作的教程

Here is an tutorial that I was able to get working.

我还阅读了有关该主题的官方SDK文档:组合标签栏和导航控制器。由于我还在学习,教程帮助了我比文档更多。

I also read the official SDK documentation on the topic: Combining Tab Bar and Navigation Controllers. Since I'm still learning, the tutorial helped me more than the docs.

注意:在教程中,我认为你不需要继承UINavigationController,我现在正在尝试这个想法。

NOTE: in the tutorial, i don't think you need to subclass UINavigationController, and I'm experimenting with this idea now.

更新:我能够得到教程在没有子类化UINavigationController的情况下工作。因此不需要子类。

UPDATE: I was able to get the tutorial working without subclassing UINavigationController. So a subclass is not required.

这篇关于如何:标签栏控制器中的导航控制器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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