开发者

Android: Why use imagebutton?

开发者 https://www.devze.com 2023-03-28 12:07 出处:网络
Warning: I am a noob so this might not be a \"regular question\". My question: Instead of using an imagebutton in Android isnt it the same to use an image, make clickable=true and then use that onCli

Warning: I am a noob so this might not be a "regular question".

My question: Instead of using an imagebutton in Android isnt it the same to use an image, make clickable=true and then use that onClick as well?

Isnt that the same? Or am I missing something?

The only thing my google ventures has given me is that you can hav开发者_JS百科e different states onPressed, onReleased etc but that too can easily be done via the java code.

What am I missing?

Thanks!


ImageButton gives you more control on how to display the image than if you were using the base View class.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号