Hi I want to have a progress bar for image which will shown while image loading but when image loading will be completed I want to set it to gone. Earlier I was using Picasso library for this. But I don't know how to use it with Glide library. I have idea that some resource ready function is there but I don't know how to use it. Can anyone help me?
Code for Picasso Library
Picasso.with(mcontext).load(imgLinkArray.get(position).mUrlLink)
.into(imageView, new Callback() {
@Override
public void onSuccess() {
progressBar.setVisibility(View.GONE);
}
@Override
public void onError() {
}
})
;
Now How Can I do this with Glide?
Glide.with(mcontext).load(imgLinkArray.get(position).mUrlLink)
.into(imageView);
I am able to load image by this with Glide but how can I write progressBar.setVisibility(View.GONE);
somewhere in code if image get loaded?