Last active
June 10, 2020 17:52
-
-
Save mdavalos1993/474fd59511b1452df08e4c0d2c5392fa to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Glide.with(this) | |
.load("imageUrl") | |
.into(object : CustomTarget<Drawable>(850, 850) { | |
override fun onLoadCleared(placeholder: Drawable?) { | |
// called when imageView is cleared. If you are referencing the bitmap | |
// somewhere else too other than this imageView clear it here | |
} | |
override fun onResourceReady(resource: Drawable, transition: Transition<in Drawable>?) { | |
img_view.setImageDrawable(resource) | |
//do any aditional action | |
} | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment