forked from mirrors/linphone-iphone
Do not trigger onEnterBackground // onEnterForeground corecontext event when there is a call in progress. This avoids a UI deadlock from iOS video filters when entering foreground with video capture active
This commit is contained in:
parent
0b910ca190
commit
b3d83c1580
1 changed files with 9 additions and 7 deletions
|
|
@ -237,13 +237,15 @@ struct LinphoneApp: App {
|
|||
}
|
||||
}
|
||||
}.onChange(of: scenePhase) { newPhase in
|
||||
if newPhase == .active {
|
||||
Log.info("Entering foreground")
|
||||
coreContext.onEnterForeground()
|
||||
} else if newPhase == .inactive {
|
||||
} else if newPhase == .background {
|
||||
Log.info("Entering background")
|
||||
coreContext.onEnterBackground()
|
||||
if !TelecomManager.shared.callInProgress {
|
||||
if newPhase == .active {
|
||||
Log.info("Entering foreground")
|
||||
coreContext.onEnterForeground()
|
||||
} else if newPhase == .inactive {
|
||||
} else if newPhase == .background {
|
||||
Log.info("Entering background")
|
||||
coreContext.onEnterBackground()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue