mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 21:33:26 +00:00
Show the call buttons on macOS when the experimental native calling feature is enabled. (#6183)
* Show the call buttons on macOS when the experimental native calling feature is enabled. * Start native calls in their own window on macOS. * Update the Enterprise submodule.
This commit is contained in:
@@ -57,6 +57,8 @@ struct RoomScreenViewState: BindableState {
|
||||
|
||||
/// Whether or not starting a call is supported.
|
||||
var isCallingEnabled = true
|
||||
/// Whether or not calls are using the experimental native implementation.
|
||||
var isNativeCallingEnabled = false
|
||||
/// Whether or not the user is allowed to join calls in this room.
|
||||
var canJoinCall = false
|
||||
/// Whether or not this room currently has a call in progress.
|
||||
|
||||
@@ -69,6 +69,7 @@ class RoomScreenViewModel: RoomScreenViewModelType, RoomScreenViewModelProtocol
|
||||
|
||||
let viewState = RoomScreenViewState(roomTitle: roomProxy.infoPublisher.value.displayNameOrID,
|
||||
roomAvatar: roomProxy.infoPublisher.value.avatar,
|
||||
isNativeCallingEnabled: appSettings.nativeCallEnabled,
|
||||
hasOngoingCall: roomProxy.infoPublisher.value.hasRoomCall,
|
||||
isDM: roomProxy.infoPublisher.value.isDM,
|
||||
hasSuccessor: roomProxy.infoPublisher.value.successor != nil,
|
||||
|
||||
@@ -316,7 +316,7 @@ struct RoomScreen: View {
|
||||
}
|
||||
}
|
||||
|
||||
if !ProcessInfo.processInfo.isiOSAppOnMac {
|
||||
if !ProcessInfo.processInfo.isiOSAppOnMac || context.viewState.isNativeCallingEnabled {
|
||||
if context.viewState.shouldShowCallButton {
|
||||
RoomCallControlsToolbar(viewState: context.viewState) { isVoiceCall in
|
||||
context.send(viewAction: .displayCall(isVoiceCall: isVoiceCall))
|
||||
|
||||
Reference in New Issue
Block a user