What are the official Android recommendations for tabs?

徘徊边缘 提交于 2019-12-01 00:46:47

"Global" is used in a local context here. :) The intent of that statement is to say that action bar tabs should be used for activity-global navigation, and that you should refrain from using action bar tabs to switch navigation within a sub-pane of the same activity.

This mostly applies to large-screen or tablet layouts where you might have multiple panes of content. If you use action bar tabs in such a configuration, it wouldn't make sense for those tabs to only apply to the right detail pane of the activity but leave a left pane alone. If you wanted tabs that only apply to a single pane of an activity, those tabs should be part of that pane rather than part of the action bar.

Basically, tabs should always be local to the content that they affect. If switching tabs switches between different content for the whole activity window, use action bar tabs. If tabs are more local to a smaller part of your UI, place them closer to the content that will actually change when you select a new tab.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!