Make the editor ask for confirmation before closing