Media notification persists after stopping playback
Steps to reproduce:
- Enable the stop button in Layout & Theme > Customization > enable here.
- Play a song/playlist/album
- Close the app
- Stop queue with media notification
- Press play in media notification
Excepted behavior after stop button is pressed is to either
- remove the media notification when the stop button is pressed or
- attempt to resume last queue or restart last queue from the beginning when play button is pressed.
The stop button clears the queue, which also means that after an app restart it will not be restored automatically. That the notification is still visible is just a bug, I'll try to look into it.
Is this settings or platform-specific? I don't see a stop button either in-app or in the notification on Android.
@corngood
Enable the stop button in Layout & Theme > Customization > enable here.
It's one of the toggles under customization menu.
Enable the stop button in Layout & Theme > Customization > enable here.
I'm sorry, assuming that didn't get added later on, I clearly didn't read it very well.
I can't reproduce this on my local build, which makes me think it might be fixed by #1148.
When I hit stop on the notification, the notification gets removed immediately.
Close the app
Do you mean simply minimising it? That's what I'm testing. I haven't tried killing it yet (force stop removes the notification immediately, and I'm having adb trouble, so I can't test adb am kill right now).
so I can't test adb am kill right now
I tested this. After the app is killed, the notification no longer has a stop button (or seek bar, etc), so you can only hit play, wait for the app to restart, and then hit stop.
@flloschy @f-4dev is this your issue too?
sounds like it whats your OS @corngood?
GrapheneOS latest (at the time) on a pixel 8a.
Haha @F-4Dev and I are also using graphene
Im abit disconnected from this problem, does it work on normal android @Chaphasilor? I forgot
Happens for me too. (Pixel 6 with GOS).
But found another small inconsistency while testing this
https://github.com/jmshrv/finamp/issues/1321
The same issue btw also happen upon holding the notification and clicking "hide" which doesn't really only hide the notification but also closes the app. But upon swiping down again the notification is still there without the queue. This is similar to this issue I made
No, doesn't work for me either 🙃
First stop actually seems to "pause" (stop and like button still shown), second stop leads to the state without progress bar or buttons, just the play button. Finamp is still active in the background (disabled battery optimizations).
Restoring via play also doesn't work in that state (I'm guessing there's a play event we're not handling correctly, where we could restore the moat recent queue).
So I guess we somehow need to manually remove the notification on stop?
Should be possible somewhere in audio_service...