Cleaning code behind GUI