X button now closes the program.