Fix threading for Qt5.

Fix GL Context on Qt5.
Also fix EmuThread loop.

Working fine on Linux.
You could use an atomic variable for `stop_run`, remove the mutex, and move this condition to the `while` expression.