-c closes the dialog and still triggers the close event, which is what we want...