In my app I download an image from an URL and set it into an ImageView through Glide, however, I\'m trying to remove a few unnecessary layouts, so is it possible to use Glide to
In Glide 4.9.0 SimpleTarget is deprecated. You can use CustomTarget instead.
Glide.with(myFragmentOrActivity)
.load(imageUrl)
.into(new CustomTarget(100,100) {
@Override
public void onResourceReady(@NonNull Drawable resource, @Nullable Transition super Drawable> transition)
{
left.setCompoundDrawablesWithIntrinsicBounds(null, resource, null, null);
}
@Override
public void onLoadCleared(@Nullable Drawable placeholder)
{
left.setCompoundDrawablesWithIntrinsicBounds(null, placeholder, null, null);
}
});