Ahmad ElMadi
Ahmad ElMadi

Reputation: 2617

Android TV: Using tab layout

I would like to ask if using TabLayout for TV apps is a recommended way for navigation or not ? The reason why I am using tablayout is that in my app i receive channels from a server and the channels belong to different categories

Upvotes: 1

Views: 4220

Answers (3)

joke4me
joke4me

Reputation: 842

Update 2020 :

Now there's official support for TabLayout on Android TV with LeanbackTabLayout Code snippet and screenshots available here https://developer.android.com/training/tv/start/libraries#leanback-tabs-library

Upvotes: 3

Shu Zhang
Shu Zhang

Reputation: 561

Google has a sample of TabLayout now.

https://github.com/googlecodelabs/android-tv-leanback/blob/master/checkpoint_2/src/main/java/com/android/example/leanback/SlidingTabLayout.java

Here is the partial screenshot of the sample.

enter image description here

Upvotes: 2

Sathiamour
Sathiamour

Reputation: 137

Using TabLayout for TV is not an good idea. Even though It supports on Android TV the user experience look was not so good. It is out fit for bigger screens and not give the Cinematic experience.

For TV experience, Google has created a Leanback Support Library which contains APIs to support building user interfaces on TV devices. To Show different channels grouped up in to categories - you should use BrowserFragment. It is composed with RowFragment and HeaderFragment.

For More Details for TV Design Guide lines:

Upvotes: 0

Related Questions