我自定义了一个 RadioButton 样式,用于在右侧添加单选按钮图像
<RadioButton
android:layout_margin="20dp"
android:drawableRight="@drawable/custom_btn_radio"
android:button="@null"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Invite Only"/>
custom_btn_radio.xml
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/check_box" android:state_checked="false"/>
<item android:drawable="@drawable/close_btn" android:state_checked="true"/>
</selector>
但是,单选按钮的连锁反应也扩大了。我怎样才能消除 RadioButton 的涟漪效应?以及如何自定义涟漪效应?
先感谢您。
原文由 Riyas PK 发布,翻译遵循 CC BY-SA 4.0 许可协议
使 RadioButton 背景透明
要么