Disable Hardware Media Keys Support in Chrome

A new feature that landed in Chrome 73 is support for hardware Media Keys. Whenever you press one of the play/pause/next/prev buttons on your keyboard, Chrome can now respond to this.

video.addEventListener('pause', function() {
  // Video is now paused.
  // TODO: Let's update UI accordingly.
});

video.addEventListener('play', function() {
  // Video is now playing.
  // TODO: Let's update UI accordingly.
});

~

Whilst this might be a good addition for many, it doesn’t work me, as I’m constantly playing music through iTunes. With iTunes jingling around, here’s my experience:

  • Open a site with a video and watch it play
  • Hit (keyboard) pause button to pause iTunes
  • Not iTunes but the video in the browser gets paused (😠)
  • CMD+TAB into iTunes
  • Hit (keyboard) pause button to pause iTunes
  • Video in the browser resumes playback (with iTunes still playing too) (😡)

Looks like the browser (or macOS?) isn’t properly releasing/giving the focus, redirecting all media keys’ keystrokes to Chrome (instead of the focussed iTunes).

~

Thankfully, one can disable the support for Hardware Media Keys through some flags.

  1. Visit chrome://flags/#hardware-media-key-handling
  2. Set the dropdown value to “Disabled”
  3. Restart Chrome

Ah, much better now!

Did this help you out? Like what you see?
Consider donating.

I don’t run ads on my blog nor do I do this for profit. A donation however would always put a smile on my face though. Thanks!

☕️ Buy me a Coffee ($3)

Leave a comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.