Which user expects spaces to be sorted by id? Use the display name
Change-Id: Ic843ca00bef6dcbf0eac2c4931dea7668c9edc04
This commit is contained in:
parent
d3ca5d0db0
commit
d0579cb59b
|
@ -37,6 +37,7 @@ import org.matrix.android.sdk.api.session.room.model.RoomSummary
|
|||
import org.matrix.android.sdk.api.session.room.model.SpaceChildInfo
|
||||
import org.matrix.android.sdk.api.session.room.summary.RoomAggregateNotificationCount
|
||||
import org.matrix.android.sdk.api.util.toMatrixItem
|
||||
import java.util.Locale
|
||||
import javax.inject.Inject
|
||||
|
||||
class SpaceSummaryController @Inject constructor(
|
||||
|
@ -140,7 +141,7 @@ class SpaceSummaryController @Inject constructor(
|
|||
}
|
||||
|
||||
rootSpaces
|
||||
?.sortedBy { it.roomId }
|
||||
?.sortedBy { it.displayName.toLowerCase(Locale.getDefault()) }
|
||||
?.forEach { groupSummary ->
|
||||
val isSelected = selected is RoomGroupingMethod.BySpace && groupSummary.roomId == selected.space()?.roomId
|
||||
// does it have children?
|
||||
|
|
Loading…
Reference in New Issue