Merge and remove util classes
This commit is contained in:
@@ -12,6 +12,7 @@ import android.widget.ImageView
|
||||
fun ImageView.setVectorCompat(@DrawableRes drawable: Int, tint: Int? = null) {
|
||||
val vector = VectorDrawableCompat.create(resources, drawable, context.theme)
|
||||
if (tint != null) {
|
||||
vector?.mutate()
|
||||
vector?.setTint(tint)
|
||||
}
|
||||
setImageDrawable(vector)
|
||||
|
||||
Reference in New Issue
Block a user