Cleaned GUI code