my F8/PlayPause key on Mac OS Catalina (10.15.6) only opens and controls the Music app. Previously, it used to play/pause the active video on Chrome or Safari. This is especially useful for doing coding tutorials on Udemy - I can have the video open in my secondary screen and the text editor/IDE open in my main screen, and can pause/play the video with the pause button.
However, this functionality stopped working about a week ago. At first, the Play/Pause key did nothing. Now, pressing the key will open the Music app if it's not already open, and it only works for that.
I've tried using BetterTouchTool to run an AppleScript script when F5 is pushed that will do the same thing, but nothing happens. The script I tried for Safari is:
tell application "Safari"
playpause
end tell
but this does absolutely nothing.
Any help here would be good.