Fix handling of ESC key in popups (fixes#17)
This commit changes the behavior of the escape key from closing the current
gui screen to only closing the current layer of the gui screen. E.g. pressing
ESC closes the popup but not the gui screen, it used to close both