I wanted to leave an ImageButton is disabled (not clickable) but have used android: enabled = "false" and does't work.
ImageButton
android: enabled = "false"
Does anyone know how to disable an ImageButton?
If you want to show the button as disabled (if you have that set up in an xml drawable file) doing both setClickable(false) AND setEnabled(false) will do the trick.
setClickable(false)
setEnabled(false)
2.1m questions
2.1m answers
60 comments
57.0k users