Fixes wrong voice message being displayed and played on the timeline.

This commit is contained in:
Jorge Martín 2022-07-14 13:18:48 +02:00 committed by Jorge Martin Espinosa
parent ac7aa9f31d
commit 6c1016caff
2 changed files with 3 additions and 2 deletions

1
changelog.d/6213.bugfix Normal file
View file

@ -0,0 +1 @@
Fixes wrong voice message being displayed and played on the timeline.

View file

@ -24,7 +24,7 @@ import android.view.View
import android.view.ViewGroup
import android.widget.ImageButton
import android.widget.TextView
import androidx.core.view.doOnLayout
import androidx.core.view.doOnPreDraw
import androidx.core.view.isVisible
import com.airbnb.epoxy.EpoxyAttribute
import com.airbnb.epoxy.EpoxyModelClass
@ -84,7 +84,7 @@ abstract class MessageVoiceItem : AbsMessageItem<MessageVoiceItem.Holder>() {
holder.progressLayout.isVisible = false
}
holder.voicePlaybackWaveform.doOnLayout {
holder.voicePlaybackWaveform.doOnPreDraw {
onWaveformViewReady(holder)
}