Fix / kebab menu not always visible in space item

Bug due to cell reuse not showing back menu
This commit is contained in:
Valere 2021-04-26 15:45:34 +02:00
parent 3378e23cc2
commit 872c45d5a3
1 changed files with 1 additions and 12 deletions

View File

@ -55,6 +55,7 @@ abstract class SpaceSummaryItem : VectorEpoxyModel<SpaceSummaryItem.Holder>() {
holder.groupNameView.text = matrixItem.displayName
holder.rootView.isChecked = selected
if (onMore != null) {
holder.moreView.isVisible = true
holder.moreView.setOnClickListener(
DebouncedClickListener({ _ ->
onMore?.invoke()
@ -66,16 +67,6 @@ abstract class SpaceSummaryItem : VectorEpoxyModel<SpaceSummaryItem.Holder>() {
holder.secondLineText.setTextOrHide(description)
if (hasChildren) {
// holder.collapseIndicator.setOnClickListener(
// DebouncedClickListener({ _ ->
// toggleExpand?.invoke()
// })
// )
// when (expanded) {
// null -> {
// holder.collapseIndicator.isGone = true
// }
// else -> {
holder.collapseIndicator.isVisible = true
holder.collapseIndicator.setImageDrawable(
ContextCompat.getDrawable(holder.view.context,
@ -87,8 +78,6 @@ abstract class SpaceSummaryItem : VectorEpoxyModel<SpaceSummaryItem.Holder>() {
toggleExpand?.invoke()
})
)
// }
// }
} else {
holder.collapseIndicator.isGone = true
}