Refactoring.
Quit button in menu works now