I’ve been trying to use JUCE for a general media app and found myself stuck when trying to configure an assortment of input shortcuts. This is particularly off-putting because I need to use a remote control for the app on an embedded device.
To summarise the missing media key input functionality:
- pause (Note that this is different than the play/pause key)
- volume up
- volume down
- channel up
- channel down
In terms of Linux’s input events (which JUCE doesn’t apparently use, unless I’m confused? See https://github.com/torvalds/linux/blob/master/include/uapi/linux/input-event-codes.h ):
Some investigations have found this for Linux/X11, but it’s incomplete in terms of media keys: https://cgit.freedesktop.org/xorg/proto/x11proto/tree/XF86keysym.h#n36
For macOS, this is what I could conjure up:
Note: it looks like macOS idiotically controls volume up/down/mute at a lower level. See: https://developer.apple.com/documentation/appkit/nsevent/1535851-function-key_unicodes
Note that some function keys are handled at a lower level and are never seen by your app. They include the Volume Up key, Volume Down key, Volume Mute key, Eject key, and Function key found on many computers.