Untitled
unknown
plain_text
2 years ago
727 B
9
Indexable
private fun renderGender(): Unit = with(binding) {
val genderMap = mapOf(
MALE_KEY to Pair(
context.getString(R.string.feature_mamiads_title_male),
BasicIcon.MALE
),
FEMALE_KEY to Pair(
context.getString(R.string.feature_mamiads_title_female),
BasicIcon.FEMALE
)
)
val (genderText, genderIcon) = genderMap[state.gender?.toLowerCase()] ?: Pair("", null)
genderTextView.apply {
visible()
text = genderText
}
genderIconCV.apply {
visible()
bind {
imageDrawable = genderIcon
}
}
}Editor is loading...