ImageView onImageChangedListener Android

后端 未结 3 1581
一整个雨季
一整个雨季 2020-12-10 03:57

Is there an onImageChangedListener() on a ImageView?

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

3条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-12-10 04:56

    If you want to load the image from network and check change in imageview you can use imageView.isAttachedToWindow(). I have tried downloading the image from network and disabled the progressbar after image downloaded and attached to window. Use,

             if(imageView.isAttachedToWindow()){ 
                //your code here
              }
    

提交回复
热议问题