Putting It on My Tab

 

The general Android philosophy is to keep activities short and sweet. If there is more information than can reasonably fit on one screen, albeit perhaps with scrolling, then it most likely belongs in another activity kicked off via an , as will be described Chapter 24. However, that can be complicated to set up. Moreover, sometimes there legitimately is a lot of information that needs to be collected to be processed as an atomic operation.

In a traditional UI, you might use tabs to accomplish this end, such as a in Java/Swing. In Android, you now have an option of using a container in much the same way – a portion of your activity’s screen is taken up with tabs which, when clicked, swap out part of the view and replace it with something else. For example, you might have an activity with a tab for entering a location and a second tab for showing a map of that location.

Some GUI toolkits refer to “tabs” as being just the things a user clicks on to toggle from one view to another. Some toolkits refer to “tabs” as being the combination of the clickable button‑ish element and the content that appears when that tab is chosen. Android treats the tab buttons and contents as discrete entities, so we will call them “tab buttons” and “tab contents” in this section.

 








Дата добавления: 2015-05-16; просмотров: 620;


Поиск по сайту:

При помощи поиска вы сможете найти нужную вам информацию.

Поделитесь с друзьями:

Если вам перенёс пользу информационный материал, или помог в учебе – поделитесь этим сайтом с друзьями и знакомыми.
helpiks.org - Хелпикс.Орг - 2014-2024 год. Материал сайта представляется для ознакомительного и учебного использования. | Поддержка
Генерация страницы за: 0.003 сек.