Delegate call notifications to Element Call, upgrade SDK and EC embedded (#5119)

* Stop sending call notifications manually: the Element Call widget can now assume responsibility for sending them when you start a call.

* Upgrade SDK version to `v25.8.5`, fix API breaks

* Upgrade Element Call embedded to `v0.14.1`

* Fix tests and lint issues

* Add `RoomListEntriesDynamicFilterKind.NonSpace` to avoid displaying spaces in the room list

---------

Co-authored-by: Robin <robin@robin.town>
This commit is contained in:
Jorge Martin Espinosa 2025-08-05 17:14:51 +02:00 committed by GitHub
parent bfdcc97985
commit dff295eadf
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
17 changed files with 64 additions and 174 deletions

View file

@ -55,7 +55,6 @@ class FakeJoinedRoom(
private val roomNotificationSettingsService: FakeNotificationSettingsService = FakeNotificationSettingsService(),
private var createTimelineResult: (CreateTimelineParams) -> Result<Timeline> = { lambdaError() },
private val editMessageLambda: (EventId, String, String?, List<IntentionalMention>) -> Result<Unit> = { _, _, _, _ -> lambdaError() },
private val sendCallNotificationIfNeededResult: () -> Result<Boolean> = { lambdaError() },
private val progressCallbackValues: List<Pair<Long, Long>> = emptyList(),
private val generateWidgetWebViewUrlResult: (MatrixWidgetSettings, String, String?, String?) -> Result<String> = { _, _, _, _ -> lambdaError() },
private val getWidgetDriverResult: (MatrixWidgetSettings) -> Result<MatrixWidgetDriver> = { lambdaError() },
@ -207,10 +206,6 @@ class FakeJoinedRoom(
return getWidgetDriverResult(widgetSettings)
}
override suspend fun sendCallNotificationIfNeeded(): Result<Boolean> = simulateLongTask {
sendCallNotificationIfNeededResult()
}
override suspend fun setSendQueueEnabled(enabled: Boolean) = simulateLongTask {
setSendQueueEnabledResult(enabled)
}

View file

@ -11,12 +11,12 @@ import io.element.android.libraries.matrix.api.widget.CallWidgetSettingsProvider
import io.element.android.libraries.matrix.api.widget.MatrixWidgetSettings
class FakeCallWidgetSettingsProvider(
private val provideFn: (String, String) -> MatrixWidgetSettings = { _, _ -> MatrixWidgetSettings("id", true, "url") }
private val provideFn: (String, String, Boolean, Boolean) -> MatrixWidgetSettings = { _, _, _, _ -> MatrixWidgetSettings("id", true, "url") }
) : CallWidgetSettingsProvider {
val providedBaseUrls = mutableListOf<String>()
override suspend fun provide(baseUrl: String, widgetId: String, encrypted: Boolean): MatrixWidgetSettings {
override suspend fun provide(baseUrl: String, widgetId: String, encrypted: Boolean, direct: Boolean): MatrixWidgetSettings {
providedBaseUrls += baseUrl
return provideFn(baseUrl, widgetId)
return provideFn(baseUrl, widgetId, encrypted, direct)
}
}