Announcements

Media keys stopped working after latest update(1.1.56.595.g2d2da0de)

Solved!
Reply

Media keys stopped working after latest update(1.1.56.595.g2d2da0de)

ltrager
Casual Listener

I am running the Spotify Snap with a premium account directly from the Snap store on Ubuntu 20.10. Media keys from my keyboard(Das Keyboard 4 Pro) have always worked perfectly with the Spotify Snap. With the most recent update, 1.1.56.595.g2d2da0de, media keys have stopped working. They work fine in other applications.

 

In the attached dump I tried using the play, previous, and next button on my keyboard. When those didn't work I click the play button then tried pause, previous, and next on my keyboard. In either case the media keys did not work.

1 ACCEPTED SOLUTION

Accepted Solutions
Solution!

Re: Media keys stopped working after latest update(1.1.56.595.g2d2da0de)

n3uromanc3r
Regular

I experienced this issue and managed to trace it down to Firefox.  I unchecked "Control media via keyboard, headset, or virtual interface" in Firefox preferences and after restarting my machine, media keys worked again.  I presume I started Firefox before Spotify and Firefox took control of the media keys.  It's worth noting that Chrome also has media keys functionality, and so you might want to check that too (https://community.spotify.com/t5/Desktop-Windows/Media-keys-being-taken-over-by-chrome-tabs/td-p/473...)

Hope this helps!

View solution in original post

3 Replies

Re: Media keys stopped working after latest update(1.1.56.595.g2d2da0de)

Sebasty
Rock Star 18
Rock Star 18

Hey @ltrager 

 

That's odd!
I am not quite sure what could be the cause of this specifically, but you could create global keyboard shortcuts for Spotify using dbus-driven commands.

They work when Spotify is running and when it's not, other programs get the attention.

 

The commands are:

Play/Pause
dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.PlayPause

Next
dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Next

Previous
dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Previous

 

I got the new update yesterday and confirmed they still work as expected.

 

Hope this is of any help; have a lovely day 🙂

SebastyRock Star 18
Help others find this answer and click "Accept as Solution".
If you appreciate my answer, maybe give me a Like.
Note: I'm not a Spotify employee.
Solution!

Re: Media keys stopped working after latest update(1.1.56.595.g2d2da0de)

n3uromanc3r
Regular

I experienced this issue and managed to trace it down to Firefox.  I unchecked "Control media via keyboard, headset, or virtual interface" in Firefox preferences and after restarting my machine, media keys worked again.  I presume I started Firefox before Spotify and Firefox took control of the media keys.  It's worth noting that Chrome also has media keys functionality, and so you might want to check that too (https://community.spotify.com/t5/Desktop-Windows/Media-keys-being-taken-over-by-chrome-tabs/td-p/473...)

Hope this helps!

View solution in original post

Re: Media keys stopped working after latest update(1.1.56.595.g2d2da0de)

ltrager
Casual Listener

Starting Spotify before Firefox fixed it.

 

Thanks for the tip!

SUGGESTED POSTS