From 1b657835fc0b3ea6f5a76534787d9a82cac50e75 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Thu, 10 Apr 1997 06:29:59 +0000 Subject: [PATCH] (keyboard-escape-quit): Exit recursive edits, and switch away from buffers whose names start with space. --- lisp/simple.el | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lisp/simple.el b/lisp/simple.el index 2c9a39bce4e..7d45abc183b 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -2843,10 +2843,14 @@ or go back to just one window (by deleting all but the selected window)." ((and transient-mark-mode mark-active) (deactivate-mark)) + ((> (recursion-depth) 0) + (exit-recursive-edit)) (buffer-quit-function (funcall buffer-quit-function)) ((not (one-window-p t)) - (delete-other-windows)))) + (delete-other-windows)) + ((string-match "^ \\*" (buffer-name (current-buffer))) + (bury-buffer)))) (define-key global-map "\e\e\e" 'keyboard-escape-quit) -- 2.39.5