added code for gui shutdown & changed extension for gui only