Show ElementCalls in the system Recents list and allow deep linking back into a call from there
This commit is contained in:
committed by
Stefan Ceriu
parent
13a34be157
commit
7b12e95192
@@ -17,6 +17,7 @@
|
||||
import AnalyticsEvents
|
||||
import BackgroundTasks
|
||||
import Combine
|
||||
import Intents
|
||||
import MatrixRustSDK
|
||||
import SwiftUI
|
||||
import Version
|
||||
@@ -236,6 +237,20 @@ class AppCoordinator: AppCoordinatorProtocol, AuthenticationFlowCoordinatorDeleg
|
||||
return false
|
||||
}
|
||||
|
||||
func handleUserActivity(_ userActivity: NSUserActivity) {
|
||||
// `INStartVideoCallIntent` is to be replaced with `INStartCallIntent`
|
||||
// but calls from Recents still send it ¯\_(ツ)_/¯
|
||||
guard let intent = userActivity.interaction?.intent as? INStartVideoCallIntent,
|
||||
let contact = intent.contacts?.first,
|
||||
let roomIdentifier = contact.personHandle?.value else {
|
||||
MXLog.error("Failed retrieving information from userActivity: \(userActivity)")
|
||||
return
|
||||
}
|
||||
|
||||
MXLog.info("Starting call in room: \(roomIdentifier)")
|
||||
handleAppRoute(AppRoute.call(roomID: roomIdentifier))
|
||||
}
|
||||
|
||||
// MARK: - AuthenticationFlowCoordinatorDelegate
|
||||
|
||||
func authenticationFlowCoordinator(didLoginWithSession userSession: UserSessionProtocol) {
|
||||
|
||||
Reference in New Issue
Block a user