1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-08-10 22:11:50 +02:00

Mobile: Allow recording to continue while the app is in the background (#12330)

This commit is contained in:
Henry Heino
2025-05-27 09:20:31 -07:00
committed by GitHub
parent c9eb9af741
commit 47e4f36f97
2 changed files with 6 additions and 0 deletions

View File

@@ -100,6 +100,7 @@ const resetAudioMode = async () => {
// instead of the default one, so it's disabled when not recording:
allowsRecordingIOS: false,
playsInSilentModeIOS: false,
staysActiveInBackground: false,
});
};
@@ -129,6 +130,7 @@ const useAudioRecorder = (onFileSaved: OnFileSavedCallback, onDismiss: ()=> void
await Audio.setAudioModeAsync({
allowsRecordingIOS: true,
playsInSilentModeIOS: true,
staysActiveInBackground: true,
// Fixes an issue where opening a recording in the iOS audio player
// breaks creating new recordings.
// See https://github.com/expo/expo/issues/31152#issuecomment-2341811087

View File

@@ -118,5 +118,9 @@
<false/>
<key>NSFaceIDUsageDescription</key>
<string>$(PRODUCT_NAME) requires FaceID access to secure access to the application</string>
<key>UIBackgroundModes</key>
<array>
<string>audio</string>
</array>
</dict>
</plist>