Skip to content

Notification Bar Hidden Play/Pause Button #19

Discussion options

You must be logged in to vote

A couple of things (maybe unrelated) first.

  • Audio should be either useForNotification or isBackgroundMusic not both
  • You need to register the callbacks onAudioReady, onAudioEnd, etc. before calling initialize
  • If you are just changing audio, instead of destroying the instance, you could use changeAudioSource and changeMetadata.

There is example code over here - https://github.com/mediagrid/capacitor-native-audio/blob/main/example/src/js/example.ts

Specifically to your issue, I have seen these weird issues with the simulator. That is one of the reasons why there is some wacky code to force an update to the controls when it shouldn't need to be done...lol.

I think these issues are specific …

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@GonzaloPardoVillalibre
Comment options

Answer selected by GonzaloPardoVillalibre
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants