I am trying to apply a custom image to a checkbox in android, for this I create a check_custom.xml file in which I define a custom image for different states of the checkbox, for example:
<item android:state_checked="true" android:drawable="@drawable/btn_check_on" /> <item android:state_checked="false" android:drawable="@drawable/btn_check_off" /> <item android:state_focused="true" android:drawable="@drawable/btn_check_onfocus" /> <item android:drawable="@drawable/btn_check_off" />
Three different images in three states on checked, on focus and on unverified, and then I assign this xml file to the background attribute with flags, but I do not get the desired result, this method applies a non-standard image, as well as the default image.
android
salman roy Mar 03 2018-11-11T00: 00Z
source share