Commit 48aa4dfc authored by Lars Hansen's avatar Lars Hansen

(desktop-read): Replace mapcar with mapc.

(desktop-create-buffer): Replace mapcar with mapc. Remove redundant piece of code.
parent 5ffc01b6
2004-11-26 Lars Hansen <larsh@math.ku.dk>
* desktop.el (desktop-read): Replace mapcar with mapc.
(desktop-create-buffer): Replace mapcar with mapc. Remove
redundant piece of code.
2004-11-27 Nick Roberts <nickrob@snap.net.nz>
* progmodes/gud.el (gud-display-line): Use display-buffer
......
......@@ -711,8 +711,8 @@ It returns t if a desktop file was loaded, nil otherwise."
;; `desktop-create-buffer' puts buffers at end of the buffer list.
;; We want buffers existing prior to evaluating the desktop (and not reused)
;; to be placed at the end of the buffer list, so we move them here.
(mapcar 'bury-buffer
(nreverse (cdr (memq desktop-first-buffer (nreverse (buffer-list))))))
(mapc 'bury-buffer
(nreverse (cdr (memq desktop-first-buffer (nreverse (buffer-list))))))
(switch-to-buffer (car (buffer-list)))
(run-hooks 'desktop-delay-hook)
(setq desktop-delay-hook nil)
......@@ -855,11 +855,10 @@ directory DIRNAME."
(setq desktop-buffer-ok-count (1+ desktop-buffer-ok-count))
(setq desktop-buffer-fail-count (1+ desktop-buffer-fail-count))
(setq result nil))
(unless (bufferp result) (setq result nil))
;; Restore buffer list order with new buffer at end. Don't change
;; the order for old desktop files (old desktop module behaviour).
(unless (< desktop-file-version 206)
(mapcar 'bury-buffer buffer-list)
(mapc 'bury-buffer buffer-list)
(when result (bury-buffer result)))
(when result
(unless (or desktop-first-buffer (< desktop-file-version 206))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment