Use LayoutContainer api for ViewHolders

This commit is contained in:
moezbhatti
2019-02-23 12:22:31 -05:00
parent ae40433ba4
commit b4ac3fc0f0
17 changed files with 21 additions and 18 deletions
@@ -64,7 +64,7 @@ class ScheduledMessageAdapter @Inject constructor(
override fun onBindViewHolder(holder: QkViewHolder, position: Int) {
val message = getItem(position)!!
val view = holder.itemView
val view = holder.containerView
// GroupAvatarView only accepts recipients, so map the phone numbers to recipients
view.avatars.contacts = message.recipients.map { address -> Recipient(address = address) }
@@ -39,7 +39,7 @@ class ScheduledMessageAttachmentAdapter @Inject constructor() : QkAdapter<Uri>()
override fun onBindViewHolder(holder: QkViewHolder, position: Int) {
val attachment = getItem(position)
val view = holder.itemView
val view = holder.containerView
GlideApp.with(view).load(attachment).into(view.thumbnail)
}