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:
parent
bfdcc97985
commit
dff295eadf
17 changed files with 64 additions and 174 deletions
|
|
@ -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)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -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)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue