From 1e963bc0dc745f5b74eebdfb42f0d99a8db78e7b Mon Sep 17 00:00:00 2001 From: Benoit Marty Date: Tue, 24 Sep 2019 14:23:13 +0200 Subject: [PATCH] Fix crash: MergedHeaderItem was missing dimensionConverter --- CHANGES.md | 6 ++++++ vector/build.gradle | 2 +- .../home/room/detail/timeline/TimelineEventController.kt | 9 ++++----- 3 files changed, 11 insertions(+), 6 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 8c2372a3b1..22701ff529 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,3 +1,9 @@ +Changes in RiotX 0.6.1 (2019-09-24) +=================================================== + +Bugfix: + - Fix crash: MergedHeaderItem was missing dimensionConverter + Changes in RiotX 0.6.0 (2019-09-24) =================================================== diff --git a/vector/build.gradle b/vector/build.gradle index 697d0f36d0..1364093ddb 100644 --- a/vector/build.gradle +++ b/vector/build.gradle @@ -16,7 +16,7 @@ androidExtensions { ext.versionMajor = 0 ext.versionMinor = 6 -ext.versionPatch = 0 +ext.versionPatch = 1 static def getGitTimestamp() { def cmd = 'git show -s --format=%ct' diff --git a/vector/src/main/java/im/vector/riotx/features/home/room/detail/timeline/TimelineEventController.kt b/vector/src/main/java/im/vector/riotx/features/home/room/detail/timeline/TimelineEventController.kt index 3c212d6129..1a0e8d180b 100644 --- a/vector/src/main/java/im/vector/riotx/features/home/room/detail/timeline/TimelineEventController.kt +++ b/vector/src/main/java/im/vector/riotx/features/home/room/detail/timeline/TimelineEventController.kt @@ -31,14 +31,11 @@ import im.vector.riotx.core.date.VectorDateFormatter import im.vector.riotx.core.epoxy.LoadingItem_ import im.vector.riotx.core.extensions.localDateTime import im.vector.riotx.core.resources.UserPreferencesProvider +import im.vector.riotx.core.utils.DimensionConverter import im.vector.riotx.features.home.AvatarRenderer import im.vector.riotx.features.home.room.detail.timeline.factory.TimelineItemFactory import im.vector.riotx.features.home.room.detail.timeline.helper.* -import im.vector.riotx.features.home.room.detail.timeline.item.DaySeparatorItem -import im.vector.riotx.features.home.room.detail.timeline.item.DaySeparatorItem_ -import im.vector.riotx.features.home.room.detail.timeline.item.MergedHeaderItem -import im.vector.riotx.features.home.room.detail.timeline.item.MessageInformationData -import im.vector.riotx.features.home.room.detail.timeline.item.ReadReceiptData +import im.vector.riotx.features.home.room.detail.timeline.item.* import im.vector.riotx.features.media.ImageContentRenderer import im.vector.riotx.features.media.VideoContentRenderer import org.threeten.bp.LocalDateTime @@ -48,6 +45,7 @@ class TimelineEventController @Inject constructor(private val dateFormatter: Vec private val timelineItemFactory: TimelineItemFactory, private val timelineMediaSizeProvider: TimelineMediaSizeProvider, private val avatarRenderer: AvatarRenderer, + private val dimensionConverter: DimensionConverter, @TimelineEventControllerHandler private val backgroundHandler: Handler, userPreferencesProvider: UserPreferencesProvider @@ -312,6 +310,7 @@ class TimelineEventController @Inject constructor(private val dateFormatter: Vec mergeItemCollapseStates[event.localId] = it requestModelBuild() }.also { + it.dimensionConverter = dimensionConverter it.setOnVisibilityStateChanged(MergedTimelineEventVisibilityStateChangedListener(callback, mergedEvents)) } }