# HG changeset patch # User Juanma Barranquero # Date 1223456548 0 # Node ID 0f0acad20b9100fc1f249c6dea4cfc17f719f3ef # Parent 6847ec2b2d38f9ba070a5572a47b5314656897eb * bs.el (bs-unload-function): New function. diff -r 6847ec2b2d38 -r 0f0acad20b91 lisp/bs.el --- a/lisp/bs.el Wed Oct 08 08:48:52 2008 +0000 +++ b/lisp/bs.el Wed Oct 08 09:02:28 2008 +0000 @@ -1464,6 +1464,21 @@ (setq bs--marked-buffers nil) (bs--show-with-configuration (bs--configuration-name-for-prefix-arg arg))) +;; ---------------------------------------------------------------------- +;; Cleanup +;; ---------------------------------------------------------------------- + +(defun bs-unload-function () + "Unload the Buffer Selection library." + (let ((bs-buf (get-buffer "*buffer-selection*"))) + (when bs-buf + (with-current-buffer bs-buf + (when (eq major-mode 'bs-mode) + (bs-kill) + (kill-buffer bs-buf))))) + ;; continue standard unloading + nil) + ;; Now provide feature bs (provide 'bs)