MythFrontend: Make Xlib calls thread-safe on Linux

This seems to be required for hardware accelerated Flash playback to work
without causing mythfrontend to abort.