Updated the GUI code