从 tabGroup 的导航中删除选项卡而不将其从 tabGroup 中删除?

发布于 2024-11-14 23:11:55 字数 434 浏览 4 评论 0原文

我正在使用 Appcelerator Titanium 构建 iPhone 应用程序。我目前有一个 tabGroup 控件,它链接到应用程序的主要部分,包括主屏幕。

我想做的是仅从导航中删除“Home”选项卡,而不是从 tabGroup 对象中删除它。因此,例如,我仍然可以调用 tabGroup.setActiveTab(0) 它会将我带到主屏幕,但底部的选项卡没有“主页”按钮。

这可能吗?如果是这样,我该怎么办?

注释:不想想要隐藏整个栏,只是隐藏一个选项卡。我也不想想要从底层对象中删除屏幕,只是导航 UI。另外,我只针对 iPhone 进行开发,并不关心其他平台是否不受支持,因此仅适用于 iPhone 的解决方案是可以接受的。

I'm using Appcelerator Titanium to build an iPhone app. I currently have a tabGroup control that links to the major sections of the app, including the home screen.

What I'd like to do is remove the "Home" tab only from the navigation, without removing it from the tabGroup object. So, for example, I'd still be able to call tabGroup.setActiveTab(0) and it would take me to the home screen, but the tabs at the bottom wouldn't have a "home" button.

Is this even possible? If so, how can I do it?

Notes: I do not want to hide the whole bar, just a single tab. I also do not want to remove the screen from the underlying object, just the navigation UI. Also, I'm only developing for iPhone and don't care if other platforms aren't supported, so iPhone-only solutions are acceptable.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

等风也等你 2024-11-21 23:11:55

将主屏幕完全从选项卡组中取出,并单独管理它的显示和转换;最终,这将是一个更清洁的解决方案。

take the home screen out of the tab group completely and manage displaying it and transitioning to it separately; in the end, it will be a cleaner solution.

中二柚 2024-11-21 23:11:55

您是否尝试过 tab.hide() 或在创建选项卡时将其设置为 visible: 0

Have you tried tab.hide() or when creating the tab setting it to visible: 0?

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文