refactored GUI. End of day