This app was mentioned in 21 comments, with an average of 1.86 upvotes
Not a Tasker solution but Don't Pause! seems to do what you're looking for.
If you want a Tasker specific solution I think a way you could do it would be to have all notifications silenced by default and then create your own notification sound with Tasker if the music isn't playing (I'm not even 100% sure this will work). The idea is that you could have a profile that is triggered from Event>UI>Notification and then have a task:
A1: Java Function [ Return:manage Class Or Object:CONTEXT Function:getSystemService{AudioManager} (String) Param:audio ] A2: Java Function [ Return:%playing Class Or Object:manage Function:isMusicActive{boolean} () ] A3: If [ %playing ~ false ] A4: Create your own notification A5: End If
The isMusicActive function should return true when YouTube or Netflix are playing as well as when music apps are playing.
Also, I believe Lollipop fixes this issue.
Do you mean your phone presently pauses your music, makes a notification sound, and then does NOT resume your music?
Or do you mean your phone presently pauses your music, makes a notification sound, and then resumes your music?
If the latter, I believe you're looking for audio ducking. There are apps that can help, or you can simply lower your notifcation volume independent of ringtone and media volumes.
hotweels mentioned you can use Poweramp and there's a setting there to turn off audio ducking, but I haven't made the jump to using that as my media player just yet.
I found an app that someone on XDA made called Don't Pause! which is working for now, but I really wish there'd just be a system setting to turn this off.
https://play.google.com/store/apps/details?id=com.pierceholdings.dontpause&hl=en
You could set up AdGuard to do this. You can accomplish the same result (silencing all notifications) with Don't Pause!, but it doesn't cut internet access.
I heard about this app that will solve this issue on the phone. Not sure if it would work while connected to Android Auto. https://play.google.com/store/apps/details?id=com.pierceholdings.dontpause&hl=en
That app happens to be Don't Pause.
NOTE: it only works on notifications. It doesn't help with videos or other audios. But for notifications, it's a godsend. If you like it the dev has a pro version i guess...
Hello, sorry to reply to such an old post but I wondered if you could help me.
I've been using Don't Pause! to stop notification sounds playing over the audio while I'm listening to Spotify by setting to Vibrate and then turning it off once the media stops or is paused. However, sometimes it gets stuck on Vibrate and won't let me manually change back so I've been looking into using Tasker even though I'm very inexperienced with it.
I did some Googling and first I used Media Utilities but it seemed less reliable with Spotify. So I found this thread. I created a task just like in your comment, which sets a global variable called %isPlaying to true when %playing is true. Then I was going to create a profile for when %isPlaying was true to have the phone go into Vibrate.
One problem is, I don't know how I should have this check keep running in the background. At the moment I'm making it wait a second before looping around and initiating it at Device Boot; anything more elegant?
Anyway, I have a task that sets the phone to Vibrate when %isPlaying is true and that works regardless of whether I use Vibrate on Ringer -> On or Silent Mode -> Vibrate but I can't make another profile to come out of Vibrate again when %isPlaying is false. I tried having the task turn Silent mode off, having Vibrate On Ringer set to Off, and raising the Notification and Ringer volumes but nothing works.
Could this be because of the Lollipop volume changes? I only just upgraded to 5.1.1 (Nexus 5). When I manually set to Vibrate or Silent I do it through APM+, I've barely looked at the priority/none stuff.
I'm sure the things I'm stuck on will seem painfully obvious if you point them out but could you put me in the right direction?
Link for the lazy:
https://play.google.com/store/apps/details?id=com.pierceholdings.dontpause
Found this, hope that helps :)
Seriously dude? You couldn't bother to Google it?
There's an app for it: https://play.google.com/store/apps/details?id=com.pierceholdings.dontpause
This app does it for all notifications if you want https://play.google.com/store/apps/details?id=com.pierceholdings.dontpause
Not an closed module, but have you tried Don't Pause?