Set preferred anchor placement in chat view

Change-Id: Ie0af62d196e88f7728b3e82e79366940afd84ff2
This commit is contained in:
SpiritCroc 2021-10-27 17:33:46 +02:00
parent eddd0a185e
commit 395b146500

View File

@ -1226,6 +1226,7 @@ class RoomDetailFragment @Inject constructor(
jumpToBottomViewVisibilityManager.maybeShowJumpToBottomViewVisibilityWithDelay()
}
}
layoutManager.setPreferredAnchorPlacement(1f - TARGET_SCROLL_OUT_FACTOR)
val stateRestorer = LayoutManagerStateRestorer(layoutManager).register()
scrollOnNewMessageCallback = ScrollOnNewMessageCallback(layoutManager, timelineEventController, views.timelineRecyclerView)
// Force scroll until the user has scrolled to address the bug where the list would jump during initial loading