There is no way to select current MPRIS target
When a MPRIS client is launched, it will be the current target for keyboard media keys until it is closed, in which case the next client launched after the first one.
For example, consider these scenarios:
-
If you start a session and open, say, Spotify, you will be able to control it with media keys freely while working with other apps.
-
If you start a session, open Google Chrome and play a video on it, Chrome will be the current MPRIS client, and the media keys will control the video being played. If you then open your Spotify, the media keys will still be targeting Chrome's video. Spotify will become the current client once you Chrome is closed.
In the second scenario, the user would be required to close chrome to be able to use media keys on Spotify. There should be an easier way to select the currently active MPRIS client.