polybar / polybar/polybar-scripts
player-mpris-tail: should sort players by recency
Nobody has claimed this yet.
- Dominant language
- Shell
- Stars
- 2.6k
- Forks
- 331
- PR merge metrics
- No merged PRs in 30d
Description
When I'm playing Spotify and another thing, e.g. Pocket Casts web player, or YouTube, etc., there are multiple players. If I click the player-mpris-tail module to pause say currently-playing Pocket Casts, then Spotify suddenly shows up in the module. Possibly due to the formatted output by the module? But pressing unpause on my media keys again actually plays Pocket Casts again, yet clicking the module would resume Spotify playback instead.
It would be good to sort the players which have been "touched"/interacted with by recency, so that the module doesn't flip between players when interacting with it. The only thing that should change the order is by manually starting or stopping another player externally.
Thanks for your consideration.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the player-mpris-tail module entry point and reproduce the behavior with Spotify plus Pocket Casts or YouTube. Trace how clicking the module and using media keys affect player ordering, then verify that interaction keeps the selected player first while externally started or stopped players can change the order.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- shell
- Domain
- desktop
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100