Override and restore the normal functionality of Apple keyboard media keys in VLC?
You can use Karabiner-Elements to set the play/pause button (on my keyboard fn+F8) to always control iTunes from any App (I know Apps besides just VLC also commandeer the iTunes buttons sometimes).

Just add something like the following rule to ~/.config/karabiner/karabiner.json

{  
   "description": "Play/pause button should only control iTunes.",
   "manipulators": [  
      {  
         "from": {  
            "key_code": "f7",
            "modifiers": {  
               "mandatory": [  
                  "fn"
               ]
            }
         },
         "to": [  
            {  
               "shell_command": "osascript -e 'tell application "iTunes" to previous track'"
            }
         ],
         "type": "basic"
      },
      {  
         "from": {  
            "key_code": "f8",
            "modifiers": {  
               "mandatory": [  
                  "fn"
               ]
            }
         },
         "to": [  
            {  
               "shell_command": "osascript -e 'tell application "iTunes" to playpause'"
            }
         ],
         "type": "basic"
      },
      {  
         "from": {  
            "key_code": "f9",
            "modifiers": {  
               "mandatory": [  
                  "fn"
               ]
            }
         },
         "to": [  
            {  
               "shell_command": "osascript -e 'tell application "iTunes" to next track'"
            }
         ],
         "type": "basic"
      }
   ]
}


Get rid of the "modifiers" part if you normally press F8 without pressing fn to play/pause iTunes.

Then in Karabiner-Elements you'd add your new rule as a complex modification: