mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-03 16:10:20 +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:
@@ -940,6 +940,7 @@ class RoomFlowCoordinator: FlowCoordinatorProtocol {
|
||||
private func presentRoomDetails(isRoot: Bool, animated: Bool) async {
|
||||
let params = RoomDetailsScreenCoordinatorParameters(roomProxy: roomProxy,
|
||||
userSession: userSession,
|
||||
appSettings: flowParameters.appSettings,
|
||||
appHooks: flowParameters.appHooks,
|
||||
analyticsService: flowParameters.analytics,
|
||||
userIndicatorController: flowParameters.userIndicatorController,
|
||||
|
||||
@@ -211,6 +211,7 @@ final class SpaceSettingsFlowCoordinator: FlowCoordinatorProtocol {
|
||||
private func presentSpaceSettings(animated: Bool) {
|
||||
let coordinator = RoomDetailsScreenCoordinator(parameters: .init(roomProxy: roomProxy,
|
||||
userSession: flowParameters.userSession,
|
||||
appSettings: flowParameters.appSettings,
|
||||
appHooks: flowParameters.appHooks,
|
||||
analyticsService: flowParameters.analytics,
|
||||
userIndicatorController: flowParameters.userIndicatorController,
|
||||
|
||||
@@ -578,8 +578,13 @@ class UserSessionFlowCoordinator: FlowCoordinatorProtocol {
|
||||
}
|
||||
|
||||
let coordinator = NativeCallScreenCoordinator(parameters: .init(controller: controller))
|
||||
navigationTabCoordinator.setOverlayCoordinator(coordinator, animated: true)
|
||||
flowParameters.analytics.track(screen: .RoomCall)
|
||||
|
||||
if ProcessInfo.processInfo.isiOSAppOnMac {
|
||||
flowParameters.appMediator.windowManager.registerCoordinator(coordinator, flowCoordinator: nil, forWindowType: .call)
|
||||
} else {
|
||||
navigationTabCoordinator.setOverlayCoordinator(coordinator, animated: true)
|
||||
flowParameters.analytics.track(screen: .RoomCall)
|
||||
}
|
||||
}
|
||||
|
||||
private func restoreNativeCallScreen() {
|
||||
@@ -588,12 +593,16 @@ class UserSessionFlowCoordinator: FlowCoordinatorProtocol {
|
||||
}
|
||||
|
||||
private func dismissCallScreenIfNeeded() {
|
||||
guard navigationTabCoordinator.overlayCoordinator is CallScreenCoordinator
|
||||
|| navigationTabCoordinator.overlayCoordinator is NativeCallScreenCoordinator else {
|
||||
return
|
||||
if ProcessInfo.processInfo.isiOSAppOnMac {
|
||||
flowParameters.appMediator.windowManager.closeSecondaryWindow(forType: .call)
|
||||
} else {
|
||||
guard navigationTabCoordinator.overlayCoordinator is CallScreenCoordinator
|
||||
|| navigationTabCoordinator.overlayCoordinator is NativeCallScreenCoordinator else {
|
||||
return
|
||||
}
|
||||
|
||||
navigationTabCoordinator.setOverlayCoordinator(nil)
|
||||
}
|
||||
|
||||
navigationTabCoordinator.setOverlayCoordinator(nil)
|
||||
}
|
||||
|
||||
// MARK: - Logout
|
||||
|
||||
Reference in New Issue
Block a user