mirror of
https://github.com/zoriya/react-native-video.git
synced 2025-12-06 07:16:12 +00:00
feat: allow audio mixing if one of the video views require it (#4559)
This commit is contained in:
@@ -139,7 +139,11 @@ class AudioSessionManager {
|
||||
return view._playInBackground
|
||||
}
|
||||
|
||||
let canAllowMixing = !anyPlayerShowNotificationControls && !anyPlayerNeedsBackgroundPlayback
|
||||
let anyPlayerWantsMixing = videoViews.allObjects.contains { view in
|
||||
return view._mixWithOthers == "mix" || view._mixWithOthers == "duck"
|
||||
}
|
||||
|
||||
let canAllowMixing = anyPlayerWantsMixing || (!anyPlayerShowNotificationControls && !anyPlayerNeedsBackgroundPlayback)
|
||||
|
||||
if isAudioSessionManagementDisabled {
|
||||
// AUDIO SESSION MANAGEMENT DISABLED BY USER
|
||||
|
||||
Reference in New Issue
Block a user