I was looking for the same thing. Although it was published more than four years ago, this is one of the best posts when you post this issue, so I will answer here.
This is my decision
<?xml version="1.0" encoding="utf-8"?> <selector xmlns:android="http://schemas.android.com/apk/res/android"> <item android:state_enabled="false"> <bitmap android:alpha="@integer/disabled_alpha" android:src="@drawable/item"/> <item/> <item android:state_enabled="true" android:drawable="@drawable/item" /> </selector>
source share