My keyboard has media keys and they work globally on Unity with Banshee but don't with VLC when another app is focused.
How would I fix that?
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It only takes a minute to sign up.Sign up to join this community
I had a similar problem and the issue was that Gnome would capture the media keys before they reached VLC, to fix this you can go to "System->Preferences->Keyboard Shortcuts"
There you will see a header called sound (Expand it if needed), and remove the key combinations you want in VLC from there (You can disable them by clicking on the item and then pressing backspace).
Only problem with this is that any other applications that do use Gnome's built-in handling won't work anymore with the media keys, unless you add them again (Which in turn breaks VLC again)
VLC comes with configurable hotkey definitions. To access the hotkey menu open Tools -> Preferences -> Hotkeys:
The key for a given action can be determined by clicking on the line in between Clear and Apply. Then a window pops up to ask you for the new key combination. Press Apply to save these.
This procedure works fine with standard keyboard keys. However depending on keyboard hardware layout multimedia keys may not be recognized correctly (bug #419795, Videolan Support, Videolan on Ubuntu 10.10)
I use Ubuntu 14.04(64-bit) and VLC 2.1.5
In VLC, go to Tools > Preferences > Hotkeys. You will find three columns Action, HotKey, Global.
See the image uploaded by the user Takkat.
Click on the Global column[Next to the HotKey column] corresponding to the Action you seek, enter the media key combination and click Save.
The only workaround I could think of is to add a key modifier, e.g. press an Alt while pressing the multimedia key. That way the key combination is different from what's captured by GNOME thus it simulates the effect of using multimedia key to control VLC.
I used this only for play/pause (So the key is Alt+XF86AudioPlay, something like this; in VLC it shows as Alt+"Media Play Pause").
Here is an updated answer for Ubuntu 13.10 using VLC media player 2.0.8:
In Ubuntu, go to System Settings > Keyboard > Shortcuts > Sound and Media
Disable the key combinations you want in VLC (by clicking on the item and pressing backspace).
In VLC, go to Tools > Preferences > Hotkeys
Set the key combinations you previously disabled to a VLC action in a Global.
You can then set back the keyboard shortcut for the Ubuntu System in order for the other applications that do use Gnome's built-in handling to work. However, when VLC is running, VLC will take precedence over other applications.
EDIT: you may also need to relaunch VLC for the new hotkeys to be updated.
I got it working by downloading hotkeys in the software centre. I search hotkeys in the software centre and it shows up. It says is A hotkeys daemon for your Internet/multimedia keyboard in X.
First I download it, and than I had to disable the system hotkeys, than set the hotkeys in VLC, finally I enable the system's hotkeys. I can pause, play, and skip with the keyboard even with VLC minimize.