diff options
author | Stefan Kangas <stefankangas@gmail.com> | 2019-07-12 00:43:12 +0200 |
---|---|---|
committer | Eli Zaretskii <eliz@gnu.org> | 2019-07-20 12:23:07 +0300 |
commit | 070dd439096c0f72d8f73823649e3c650f31c890 (patch) | |
tree | 592e15fc77a298e204c7feb559d9354ce3ef159f /lisp/finder.el | |
parent | b6bef9f19311e4ea2287ac172f400d3146ba3cbb (diff) | |
download | emacs-070dd439096c0f72d8f73823649e3c650f31c890.tar.gz |
Make finder-exit use quit-window (Bug#33610)
* lisp/finder.el (finder-exit): Quit window instead of
deleting. This restores previous contents of the window,
if any, that was usurped by "C-h p" to show the list of
packages.
Diffstat (limited to 'lisp/finder.el')
-rw-r--r-- | lisp/finder.el | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lisp/finder.el b/lisp/finder.el index ad9441210c5..89706cf7dbd 100644 --- a/lisp/finder.el +++ b/lisp/finder.el @@ -465,11 +465,12 @@ finder directory, \\[finder-exit] = quit, \\[finder-summary] = help"))) (defun finder-exit () "Exit Finder mode. -Delete the window and kill all Finder-related buffers." +Quit the window and kill all Finder-related buffers." (interactive) - (ignore-errors (delete-window)) (let ((buf "*Finder*")) - (and (get-buffer buf) (kill-buffer buf)))) + (if (equal (current-buffer) buf) + (quit-window t) + (and (get-buffer buf) (kill-buffer buf))))) (defun finder-unload-function () "Unload the Finder library." |