0

I have customized a RadioGroup to work as a "tab holder". Each "tab" is a RadioButton.

I have set android:button=@nullbecause I am just using the text and also I have set a selector to the background.

When the RadioButton is checked or unchecked the selector works properly, however, when I try to add pressed state it doesn't work.

It seems it only recognizes checked or unchecked states. Any ideas? Thank you in advance.

Don Chakkappan
  • 7,397
  • 5
  • 44
  • 59
Quark
  • 402
  • 4
  • 15

1 Answers1

0

Try using state_selected in your xml selector and change RadioButton selected state from code.

lubilis
  • 3,942
  • 4
  • 31
  • 54