ImageView onImageChangedListener Android

ImageView onImageChangedListener Android(ImageView onImageChangedListener Android)

本文介绍了ImageView onImageChangedListener Android的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

ImageView 上有 onImageChangedListener() 吗?

Is there an onImageChangedListener() on a ImageView?

我需要从 ImageView 更改图像时的事件.

I need the event when the image is changed from the ImageView.

推荐答案

查看grepcode中的imageview代码.你不知道它什么时候被改变或重绘.这是因为在你 setImageDrawable() 之后,imageview 会失效.此时,在调用 ondraw 之前,图像不会正确更改.

Check the imageview code in grepcode. You don't know when it is changed or redrawn. It is because after you setImageDrawable(), imageview will invalidate. At this time, the image IS NOT CHANGED correctly until ondraw is called.

反正你为什么要知道onimagechangedlistener?

Anyway, why do you want to know the onimagechangedlistener?

这篇关于ImageView onImageChangedListener Android的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!

本文标题为:ImageView onImageChangedListener Android

基础教程推荐