mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-03 16:10:20 +00:00
Bump SDK version and fix breaking changes. (#709)
This commit is contained in:
@@ -35,11 +35,11 @@ class MockRoomSummaryProvider: RoomSummaryProviderProtocol {
|
||||
switch state {
|
||||
case .loading:
|
||||
roomListPublisher = .init([])
|
||||
statePublisher = .init(.cold)
|
||||
statePublisher = .init(.notLoaded)
|
||||
countPublisher = .init(0)
|
||||
case .loaded:
|
||||
roomListPublisher = .init(Self.rooms)
|
||||
statePublisher = .init(.live)
|
||||
statePublisher = .init(.fullyLoaded)
|
||||
countPublisher = .init(UInt(Self.rooms.count))
|
||||
}
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@ class RoomSummaryProvider: RoomSummaryProviderProtocol {
|
||||
private var cancellables = Set<AnyCancellable>()
|
||||
|
||||
let roomListPublisher = CurrentValueSubject<[RoomSummary], Never>([])
|
||||
let statePublisher = CurrentValueSubject<RoomSummaryProviderState, Never>(.cold)
|
||||
let statePublisher = CurrentValueSubject<RoomSummaryProviderState, Never>(.notLoaded)
|
||||
let countPublisher = CurrentValueSubject<UInt, Never>(0)
|
||||
|
||||
private var rooms: [RoomSummary] = [] {
|
||||
@@ -220,14 +220,14 @@ class RoomSummaryProvider: RoomSummaryProviderProtocol {
|
||||
extension RoomSummaryProviderState {
|
||||
init(slidingSyncState: SlidingSyncState) {
|
||||
switch slidingSyncState {
|
||||
case .cold:
|
||||
self = .cold
|
||||
case .preload:
|
||||
self = .preload
|
||||
case .catchingUp:
|
||||
self = .catchingUp
|
||||
case .live:
|
||||
self = .live
|
||||
case .notLoaded:
|
||||
self = .notLoaded
|
||||
case .preloaded:
|
||||
self = .preloaded
|
||||
case .partiallyLoaded:
|
||||
self = .partiallyLoaded
|
||||
case .fullyLoaded:
|
||||
self = .fullyLoaded
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -19,10 +19,10 @@ import Foundation
|
||||
import MatrixRustSDK
|
||||
|
||||
enum RoomSummaryProviderState {
|
||||
case cold
|
||||
case preload
|
||||
case catchingUp
|
||||
case live
|
||||
case notLoaded
|
||||
case preloaded
|
||||
case partiallyLoaded
|
||||
case fullyLoaded
|
||||
}
|
||||
|
||||
enum RoomSummary: CustomStringConvertible {
|
||||
|
||||
Reference in New Issue
Block a user