mirror of
https://github.com/element-hq/element-android
synced 2024-11-23 09:55:40 +03:00
stop listening timeline collection changes when app is not resumed (#7734)
This commit is contained in:
parent
ee737025f2
commit
cf59c80100
2 changed files with 3 additions and 1 deletions
1
changelog.d/7643.bugfix
Normal file
1
changelog.d/7643.bugfix
Normal file
|
@ -0,0 +1 @@
|
|||
[Notifications] Fixed a bug when push notification was automatically dismissed while app is on background
|
|
@ -975,6 +975,7 @@ class TimelineFragment :
|
|||
notificationDrawerManager.setCurrentThread(timelineArgs.threadTimelineArgs?.rootThreadEventId)
|
||||
roomDetailPendingActionStore.data?.let { handlePendingAction(it) }
|
||||
roomDetailPendingActionStore.data = null
|
||||
views.timelineRecyclerView.adapter = timelineEventController.adapter
|
||||
}
|
||||
|
||||
private fun handlePendingAction(roomDetailPendingAction: RoomDetailPendingAction) {
|
||||
|
@ -993,6 +994,7 @@ class TimelineFragment :
|
|||
super.onPause()
|
||||
notificationDrawerManager.setCurrentRoom(null)
|
||||
notificationDrawerManager.setCurrentThread(null)
|
||||
views.timelineRecyclerView.adapter = null
|
||||
}
|
||||
|
||||
private val emojiActivityResultLauncher = registerStartForActivityResult { activityResult ->
|
||||
|
@ -1058,7 +1060,6 @@ class TimelineFragment :
|
|||
it.dispatchTo(scrollOnHighlightedEventCallback)
|
||||
}
|
||||
timelineEventController.addModelBuildListener(modelBuildListener)
|
||||
views.timelineRecyclerView.adapter = timelineEventController.adapter
|
||||
|
||||
if (vectorPreferences.swipeToReplyIsEnabled()) {
|
||||
val quickReplyHandler = object : RoomMessageTouchHelperCallback.QuickReplayHandler {
|
||||
|
|
Loading…
Reference in a new issue