本文介绍了按键之间的区别与形象,ImageButton的,并点击ImageView的?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
有没有用图像,的ImageButton
键,可点击的ImageView 间
按钮
有什么区别code>?
Is there any difference between Button
with image, ImageButton
and clickable ImageView
?
推荐答案
这大概只能覆盖的不同部分,这将有助于真正看的Android源代码树,看看到底发生了什么事情。
This probably only covers part of the differences, it would be helpful to actually look at the Android Source tree to see exactly what's going on.
ImageButtons有推的状态,其中一个可点击的图片没有。你也不能说的setText为ImageButton的,你可以用一个常规的按钮。
ImageButtons has push states, where as a clickable image does not.You also can't call setText for ImageButton, you can with a regular button.
他们都从视野中获得,但看着下面的延伸链可能会有点帮助。
They all derive from view, but looking at the following extends chain may help a little.
java.lang.Object
↳ android.view.View
↳ android.widget.ImageView
↳ android.widget.ImageButton
与
java.lang.Object
↳ android.view.View
↳ android.widget.TextView
↳ android.widget.Button
这篇关于按键之间的区别与形象,ImageButton的,并点击ImageView的?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!