Dynamically adjusting the visibleRoomsView's timeline limit based on the app state

This commit is contained in:
Stefan Ceriu
2023-01-31 15:43:15 +02:00
committed by Stefan Ceriu
parent a8f154740e
commit 8f3842f74a
9 changed files with 64 additions and 25 deletions
@@ -44,7 +44,7 @@ class MockRoomSummaryProvider: RoomSummaryProviderProtocol {
}
}
func updateVisibleRange(_ range: Range<Int>) { }
func updateVisibleRange(_ range: Range<Int>, timelineLimit: UInt) { }
// MARK: - Private
@@ -61,8 +61,8 @@ class RoomSummaryProvider: RoomSummaryProviderProtocol {
.store(in: &cancellables)
}
func updateVisibleRange(_ range: Range<Int>) {
slidingSyncViewProxy.updateVisibleRange(range)
func updateVisibleRange(_ range: Range<Int>, timelineLimit: UInt) {
slidingSyncViewProxy.updateVisibleRange(range, timelineLimit: timelineLimit)
}
// MARK: - Private
@@ -50,5 +50,5 @@ protocol RoomSummaryProviderProtocol {
/// Publishes the total number of rooms
var countPublisher: CurrentValueSubject<UInt, Never> { get }
func updateVisibleRange(_ range: Range<Int>)
func updateVisibleRange(_ range: Range<Int>, timelineLimit: UInt)
}