How to set list with Radio Buttons in Android Auto?

234 Views Asked by At

I am trying to create a list with Radio Buttons as in the following picture:

Radio Button + Text

What happens is that I'm using the Row class from the androidx.car.app.model package, and I can't find any option to add a Radio Button (other than adding images or a switch).

With what class could I implement it? Thanks!

1

There are 1 best solutions below

0
Ben Sagmoe On

To make a list of radio buttons, you must make the list selectable using the setOnSelectedListener method of the ItemList.Builder.

See this code for an example.