GUI refactoring