Archived
Added further documentation, fixed slight spacing issue on course_card.xml when icon is set to R.drawable.ic_empty
This commit is contained in:
@@ -130,6 +130,13 @@ internal class CardAdapter(private var mSubst: List<Subst>, private val prefs: S
|
||||
else -> R.color.colorText
|
||||
}
|
||||
})
|
||||
|
||||
holder.iconView.visibility = if (icon == R.drawable.ic_empty) {
|
||||
View.GONE
|
||||
} else {
|
||||
View.VISIBLE
|
||||
}
|
||||
|
||||
holder.card.setCardBackgroundColor(ContextCompat.getColor(holder.iconView.context, cardBackgroundColour))
|
||||
holder.iconView.setImageResource(icon)
|
||||
holder.iconView.setColorFilter(textColor)
|
||||
|
||||
Reference in New Issue
Block a user