ChatKit
ChatKit copied to clipboard
MessageListAdapter addToStart method always add message on top of chat (instead of bottom of list)
Currently, I am using this library. There is no doubt that its nice library. But I am not sure why (probably) for me only addToStart method add new message in top of the list, instead of bottom of the list. addToEnd(msgList, reverse:true) is working fine. Here, I am adding my my app code related to this and related screen shot.
Code
private fun renderSBMessageState(state: SBMessageState) {
when (state) {
is SBMessageState.Loaded -> {
messageListAdapter.addToEnd(state.messageList, true)
chatConnectionManagerViewModel.getCurrentSBGroupChannel()?.groupChannel?.markAsRead()
}
is SBMessageState.OnNewMessage -> {
messageListAdapter.addToStart(state.message, true)
}
}
Chat screeshot:

@stfalcon Am i missing something here to setting up? Can you please help me here to figure out this.
Thanks
Up ! Is somebody succeed to figure it out ? I'm struggling with this problem too