Fixes #3041 - Video not rendering after starting or joinng a call

- not completely sure why this happens but `reportOutgoingCall` interferes with how the WebView gets access to video streams
- the call itself isn't really necessary so removing it is the simplest way forward
This commit is contained in:
Stefan Ceriu 2024-07-16 10:46:45 +03:00 committed by Stefan Ceriu
parent d295a1e4c2
commit 2cce310540
2 changed files with 3 additions and 10 deletions

View File

@ -87,6 +87,9 @@ private struct WebView: UIViewRepresentable {
webView.uiDelegate = self
webView.navigationDelegate = self
// https://stackoverflow.com/a/77963877/730924
webView.allowsLinkPreview = true
// Try matching Element Call colors
webView.isOpaque = false
webView.backgroundColor = .compound.bgCanvasDefault

View File

@ -152,16 +152,6 @@ class ElementCallService: NSObject, ElementCallServiceProtocol, PKPushRegistryDe
MXLog.info("Call provider did reset: \(provider)")
}
func provider(_ provider: CXProvider, perform action: CXStartCallAction) {
if let ongoingCallID {
provider.reportOutgoingCall(with: ongoingCallID.callKitID, connectedAt: nil)
} else {
MXLog.error("Failed starting call, missing ongoingCallID")
}
action.fulfill()
}
func provider(_ provider: CXProvider, perform action: CXAnswerCallAction) {
if let incomingCallID {
actionsSubject.send(.startCall(roomID: incomingCallID.roomID))