Implement Previous and Next Track buttons on lock screen media player controls #2226
Replies: 3 comments 7 replies
-
We would want to create this for all devices. So Mac, iOS, windows and android. Are you interested in doing all of that? Or would you be more interested in doing the IOS part and have someone else do the other platforms? |
Beta Was this translation helpful? Give feedback.
-
So let me put a bit of context to what I need from it so we can discover the best way to implement. My app has a couple of playlists, only 1 of which would play at any one time. It's lists of short previews of music tracks that users can listen to. They can either just let it play and it plays a bit of each tracks and automatically moves to the next track until it reaches the end of the list. So that would be the passive way of doing it. Inside the app users can also just click next/previous and it does the obvious. When a user clicks next (or it gets to the end of the track) it marks that track as listened and moves on. This is all implemented and working using custom buttons so the MediaElement itself is hidden (no video anyway). The tracklists are implemented in two different CollectionViews and each of the tracks in the collections have a lot more info than just the artist, title, art and url that are not relevant to the media player. Users can manipulate those playlists quite substantially and often. The reason I'm giving you this context is because I think you were suggesting to use a Playlist feature because that would mean a lot of the stuff is handled already which does make sense. With this I think you were talking about some built in Playlist that is associated with a media session or something like that. When a user clicks the Next Track button on the lock screen controls the following would need to happen:
Also when the playlists in the app are changed (which they are often) that would need to be synched to the platform session playlist (if I understood you correctly). Just as a bit of additional info, it's unlikely users would use the lock screen controls that much it's more the bluetooth control that comes with it that I've found users really use. So listening in the car for instance or using bluetooth headphones with next/previous buttons on them. Hopefully that makes sense!?! |
Beta Was this translation helpful? Give feedback.
-
While we're on the topic of MediaElement here, can someone make an event to invoke whenever the actual player gets paused? Since right now, whenever I pause the song through the lockscreen (iOS) it wouldn't update properly in-app. |
Beta Was this translation helpful? Give feedback.
-
I need access to the Previous and Next track commands from the lock screen (and via bluetooth connected devices) when media is playing via the MediaElement.
Previously I had this implemented on iOS using MPRemoteCommandCenter like this:
Beta Was this translation helpful? Give feedback.
All reactions