So it turns out that by default Ubuntu creates mappings for certain media related keys. This was preventing the keys from being seen by Qt's event system in my development code. After I removed the mappings the events started working for those keys.
Keyboard -> Shortcuts -> Sound and Media