diff options
Diffstat (limited to 'ibuffer.el')
-rw-r--r-- | ibuffer.el | 14 |
1 files changed, 8 insertions, 6 deletions
@@ -93,8 +93,8 @@ automatically.") ;;;###autoload (defun durand-ibuffer-clear (&optional arg) "Kill every buffer except for those in `durand-clear-passlist'. -If the optional ARG is non-nil, then kill every buffer except for -those that are marked." +If the optional ARG is non-nil, then restrict the range to the +marked buffers." (interactive "P") (cond ((derived-mode-p 'ibuffer-mode)) @@ -116,14 +116,16 @@ derived modes of `ibuffer-mode'."))) (mapc (function (lambda (buffer-and-mark) (cond - ((or (= (cdr buffer-and-mark) + ((or (/= (cdr buffer-and-mark) ibuffer-marked-char) - (string= (buffer-name (car buffer-and-mark)) - dashboard-buffer-name))) + (durand-member (buffer-name (car buffer-and-mark)) + durand-clear-passlist + #'string=))) ((kill-buffer (car buffer-and-mark)))))) (cons (cons (current-buffer) 32) - (ibuffer-current-state-list)))))) + (ibuffer-current-state-list))) + (ibuffer-update nil t)))) (define-key global-map (vector 24 2) #'ibuffer) (define-key global-map (vector ?\s-h) #'ibuffer) |