Skip to content
This repository was archived by the owner on Oct 6, 2022. It is now read-only.

React Native Music controls does not appear on real iOS device lock screen at all #366

Closed
krunalbad opened this issue Dec 3, 2020 · 8 comments

Comments

@krunalbad
Copy link
Contributor

krunalbad commented Dec 3, 2020

React Native Music controls does not appear on real iOS device lock screen at all
but appears on iOS simulator but controls does not work at all

but same code works 99% on android
except in android the notification does not go away on reset function

react-native: 0.63.2
react-native-music-control: 1.4.0-alpha
https://www.npmjs.com/package/react-native-music-control/v/1.4.0-alpha

Is there any other setup required for iOS ?

@krunalbad krunalbad changed the title music controls do not appear on ios lock screen at all React Native Music controls does not appear on real iOS device lock screen at all Dec 3, 2020
@krunalbad
Copy link
Contributor Author

i have did some workaround for android double notification issue.
found out the issue was from my code side. in android i works fine.
but it is still not working at all for ios.
need assistance for ios.
how to make it working for ios ? @tanguyantoine

@iamchrispham
Copy link

lock controls are displaying for me on iOS 14. I've ran into an issue on iOS but not on Android such that if there were multiple instances of some media content, you would want to ensure that the media content you'd want to display within the lock controls isn't being mixed with another media instance. natively the code has issues differentiating what media content takes precedence even if you've set native props for now playing/update playback.

@DevMMI
Copy link

DevMMI commented Dec 24, 2020

I'm having this same problem, have also tried earlier versions of this project and can't seem to get anything to show up the IOS lock screen

@DevMMI
Copy link

DevMMI commented Dec 24, 2020

Figured out my issue at least, I'm working with react-native-community/audio-toolkit and there's a bug that doesn't let their mixWithOthers flag ever get set to False, you can test this by playing your app audio at the same time as another app's audio.

If you're audio can play at the same time as another app's audio, then react-native-music-control will not work. Merging this commit into your code should solve the mixWithOthers issue in react-native-audio-toolkit, which should make your lock screen controls from this package work.

@krunalbad
Copy link
Contributor Author

krunalbad commented Dec 25, 2020

apparently i am using react-native-track-player and react-native-video that's y i am having trouble having controls in iOS
and both packages provides options mixWithOthers but none gets successful to get react-native-music-control started 😭

@DevMMI
Copy link

DevMMI commented Dec 26, 2020

@krunalbad do you set mixWithOthers to false on both those packages and react-native-music-controls still doesn't work? Try checking whether those flags are being obeyed, i.e. whether you can play audio at the same time as another app.

@krunalbad
Copy link
Contributor Author

krunalbad commented Dec 26, 2020

i have tried mixWithOthers in both pkgs trackplayer and rn-video but none helped

probably the main issue is with integrating these many pkgs together which maybe be creating conflicts i guess

@krunalbad
Copy link
Contributor Author

Closing this issue due to other pkgs conflicts

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants