mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-04 01:20:12 +00:00
feat: Render declined calls in DM timeline (#5512)
* feat: Render declined calls in DM timeline * Record preview snapshots * review: Use CallIntent constant * review: clean-up * Record preview snapshots * review: Move private field to the bottom with MARK: - Private * review: Male CallIntent a string enum to use rawValue --------- Co-authored-by: Element CI <ci@element.io>
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
//
|
||||
// Copyright 2026 Element Creations Ltd.
|
||||
//
|
||||
// SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial.
|
||||
// Please see LICENSE files in the repository root for full details.
|
||||
//
|
||||
|
||||
import Foundation
|
||||
import MatrixRustSDK
|
||||
|
||||
enum CallIntent: String, Codable, CaseIterable {
|
||||
case video, audio
|
||||
}
|
||||
|
||||
extension CallIntent {
|
||||
// periphery:ignore - Unused, but added to detect new cases when updating the SDK.
|
||||
init(rustCallIntent: MatrixRustSDK.RtcCallIntent) {
|
||||
switch rustCallIntent {
|
||||
case .audio: self = .audio
|
||||
case .video: self = .video
|
||||
}
|
||||
}
|
||||
|
||||
var rustCallIntent: MatrixRustSDK.RtcCallIntent {
|
||||
switch self {
|
||||
case .audio: .audio
|
||||
case .video: .video
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user