Allow the main frame to be closed with the ESC key