video-player: don't stop audio, mix with external media

This commit is contained in:
William Casarin
2023-05-30 18:44:36 -07:00
parent 5dc3e2635e
commit 6eecb5ef26

View File

@@ -6,6 +6,7 @@
// //
import SwiftUI import SwiftUI
import AVKit
struct TimestampedProfile { struct TimestampedProfile {
let profile: Profile let profile: Profile
@@ -315,6 +316,7 @@ struct ContentView: View {
.ignoresSafeArea(.keyboard) .ignoresSafeArea(.keyboard)
.onAppear() { .onAppear() {
self.connect() self.connect()
try? AVAudioSession.sharedInstance().setCategory(AVAudioSession.Category.playback, mode: .default, options: .mixWithOthers)
setup_notifications() setup_notifications()
} }
.sheet(item: $active_sheet) { item in .sheet(item: $active_sheet) { item in