Moved GUI stuff to new class.