window new-buffer (nth 1 entry) (nth 2 entry))
(throw 'found t)))))
- (when skipped
- ;; Show first skipped buffer.
+ (when (and skipped (not (functionp switch-to-prev-buffer-skip)))
+ ;; Show first skipped buffer, unless skip was a function.
(setq new-buffer skipped)
(set-window-buffer-start-and-point window new-buffer)))
;; nreverse here!)
(dolist (entry (reverse (window-prev-buffers window)))
(when (and (not (eq new-buffer (car entry)))
+ (not (eq old-buffer (car entry)))
(setq new-buffer (car entry))
(or (buffer-live-p new-buffer)
(not (setq killed-buffers
window new-buffer (nth 1 entry) (nth 2 entry))
(throw 'found t))))
- (when skipped
- ;; Show first skipped buffer.
+ (when (and skipped (not (functionp switch-to-prev-buffer-skip)))
+ ;; Show first skipped buffer, unless skip was a function.
(setq new-buffer skipped)
(set-window-buffer-start-and-point window new-buffer)))