Refactored code. Moved GUI code into GUI class.