Update strings

This commit is contained in:
yostyle 2023-08-08 10:46:17 +02:00
parent 4a412ffef2
commit 01a0175d40
3 changed files with 10 additions and 8 deletions

View file

@ -103,9 +103,10 @@ class RustMatrixClient constructor(
private val notificationClient = client.notificationClient().use { builder ->
builder.filterByPushRules().finish()
}
private val notificationSettings = client.getNotificationSettings()
private val notificationService = RustNotificationService(sessionId, notificationClient, dispatchers, clock)
private val notificationSettingsService = RustNotificationSettingsService(client)
private val notificationSettingsService = RustNotificationSettingsService(notificationSettings)
private val isLoggingOut = AtomicBoolean(false)

View file

@ -25,16 +25,14 @@ import kotlinx.coroutines.flow.MutableSharedFlow
import kotlinx.coroutines.flow.SharedFlow
import kotlinx.coroutines.flow.asSharedFlow
import org.matrix.rustcomponents.sdk.Client
import org.matrix.rustcomponents.sdk.NotificationClient
import org.matrix.rustcomponents.sdk.NotificationSettings
import org.matrix.rustcomponents.sdk.NotificationSettingsDelegate
import timber.log.Timber
class RustNotificationSettingsService(
private val client: Client,
private val notificationSettings: NotificationSettings
) : NotificationSettingsService {
private val notificationSettings: NotificationSettings = client.getNotificationSettings()
private val _notificationSettingsChangeFlow = MutableSharedFlow<Unit>(extraBufferCapacity = 1, onBufferOverflow = BufferOverflow.DROP_OLDEST)
override val notificationSettingsChangeFlow: SharedFlow<Unit> = _notificationSettingsChangeFlow.asSharedFlow()