fun aRoomListRoomSummary: make internal, add all fields and reorder to match RoomListRoomSummary constructor order.

This commit is contained in:
Benoit Marty 2024-01-22 10:59:42 +01:00
parent ca5850e0e5
commit 0334da7a14

View file

@ -44,23 +44,27 @@ open class RoomListRoomSummaryProvider : PreviewParameterProvider<RoomListRoomSu
) )
} }
fun aRoomListRoomSummary( internal fun aRoomListRoomSummary(
lastMessage: String? = "Last message", id: String = "!roomId:domain",
notificationMode: RoomNotificationMode? = null, name: String = "Room name",
hasUnread: Boolean = false, hasUnread: Boolean = false,
timestamp: String? = "88:88", timestamp: String? = "88:88",
hasRoomCall: Boolean = false, lastMessage: String? = "Last message",
isPlaceholder: Boolean = false, isPlaceholder: Boolean = false,
name: String = "Room name", notificationMode: RoomNotificationMode? = null,
hasRoomCall: Boolean = false,
avatarData: AvatarData = AvatarData(id, name, size = AvatarSize.RoomListItem),
isDm: Boolean = false,
) = RoomListRoomSummary( ) = RoomListRoomSummary(
id = "!roomId", id = id,
roomId = RoomId("!roomId:domain"), roomId = RoomId(id),
name = name, name = name,
hasUnread = hasUnread, hasUnread = hasUnread,
timestamp = timestamp, timestamp = timestamp,
lastMessage = lastMessage, lastMessage = lastMessage,
avatarData = AvatarData("!roomId", "Room name", size = AvatarSize.RoomListItem), avatarData = avatarData,
isPlaceholder = isPlaceholder, isPlaceholder = isPlaceholder,
userDefinedNotificationMode = notificationMode, userDefinedNotificationMode = notificationMode,
hasRoomCall = hasRoomCall, hasRoomCall = hasRoomCall,
isDm = isDm,
) )