I put the main app in a seperate class for it, because it was easier.
Roughly...
And I had to fix a threading bug.