Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Music controls don't work with background mode on iphone #133

Open
madmandrew opened this issue Jul 22, 2018 · 5 comments
Open

Music controls don't work with background mode on iphone #133

madmandrew opened this issue Jul 22, 2018 · 5 comments

Comments

@madmandrew
Copy link

Using ionic 3 and deploying to iphone. When background mode is enabled music controls don't show up at all. with background mode turned off music stops on screen lock and music controls show up but don't do anything.

cordova-plugin-music-controls: 2.1.4
cordova-ios: 4.4.0
cordova-plugin-background-mode: 0.7.2

@neoassyrian
Copy link
Contributor

Make sure you are using the UIWebView and not the new WKWebView in Ionic. (WKWebView is the default)
https://ionicframework.com/docs/wkwebview/

@madmandrew
Copy link
Author

madmandrew commented Jul 27, 2018

Tried both options for downgrading and still didn't work

I was able to get it to work by using the ionic media plugin. This for some reason runs the audio in the background without the background mode on.

@TylerAHolden
Copy link

TylerAHolden commented Aug 23, 2018

@khevamann
Copy link

This plugin doesn't use https://github.com/katzer/cordova-plugin-background-mode though right? or am I supposed to install the plugin?

@ghenry22
Copy link
Contributor

ghenry22 commented Dec 1, 2018

The problem with the background mode plugin is that it plays a silent audio file in the background continuously to fake activity and stop suspension of the app even when it's idle. It may be fixed now but the problem was that the background-mode plugin steals the audio session.

I would recommend giving the ionic-webview plugin a look if you want background processing support as it enables background processing but doesn't fake any work load so the OS can still suspend your add as it needs to when it is idle.

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

No branches or pull requests

5 participants