Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
63cd5734
Commit
63cd5734
authored
Nov 12, 2004
by
Eli Zaretskii
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(desktop-create-buffer, desktop-save): Avoid some consing by using mapc
instead of mapcar.
parent
d8dfe187
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
13 deletions
+18
-13
lisp/ChangeLog
lisp/ChangeLog
+5
-0
lisp/desktop.el
lisp/desktop.el
+13
-13
No files found.
lisp/ChangeLog
View file @
63cd5734
2004-11-12 Kevin Rodgers
<ihs_4664
@
yahoo.com
>
(tiny change)
* desktop.el (desktop-create-buffer, desktop-save): Avoid some
consing by using mapc instead of mapcar.
2004-11-12 Nick Roberts
<nickrob
@
snap.net.nz
>
* tooltip.el (require): Explain why CL is needed.
...
...
lisp/desktop.el
View file @
63cd5734
...
...
@@ -636,7 +636,7 @@ See also `desktop-base-file-name'."
";; Desktop file format version "
desktop-file-version
"\n"
";; Emacs version "
emacs-version
"\n\n"
";; Global section:\n"
)
(
mapc
ar
(
function
desktop-outvar
)
desktop-globals-to-save
)
(
mapc
(
function
desktop-outvar
)
desktop-globals-to-save
)
(
if
(
memq
'kill-ring
desktop-globals-to-save
)
(
insert
"(setq kill-ring-yank-pointer (nthcdr "
...
...
@@ -644,15 +644,15 @@ See also `desktop-base-file-name'."
" kill-ring))\n"
))
(
insert
"\n;; Buffer section -- buffers listed in same order as in buffer list:\n"
)
(
mapc
ar
#'
(
lambda
(
l
)
(
if
(
apply
'desktop-save-buffer-p
l
)
(
progn
(
insert
"(desktop-create-buffer "
desktop-file-version
)
(
mapc
ar
#'
(
lambda
(
e
)
(
insert
"\n "
(
desktop-value-to-string
e
)))
l
)
(
insert
")\n\n"
))))
info
)
(
mapc
#'
(
lambda
(
l
)
(
if
(
apply
'desktop-save-buffer-p
l
)
(
progn
(
insert
"(desktop-create-buffer "
desktop-file-version
)
(
mapc
#'
(
lambda
(
e
)
(
insert
"\n "
(
desktop-value-to-string
e
)))
l
)
(
insert
")\n\n"
))))
info
)
(
setq
default-directory
dirname
)
(
when
(
file-exists-p
filename
)
(
delete-file
filename
))
(
let
((
coding-system-for-write
'emacs-mule
))
...
...
@@ -873,9 +873,9 @@ directory DIRNAME."
((
equal
'
(
nil
)
desktop-buffer-minor-modes
)
; backwards compatible
(
auto-fill-mode
0
))
(
t
(
mapc
ar
#'
(
lambda
(
minor-mode
)
(
when
(
functionp
minor-mode
)
(
funcall
minor-mode
1
)))
desktop-buffer-minor-modes
)))
(
mapc
#'
(
lambda
(
minor-mode
)
(
when
(
functionp
minor-mode
)
(
funcall
minor-mode
1
)))
desktop-buffer-minor-modes
)))
;; Even though point and mark are non-nil when written by `desktop-save'
;; they may be modified by handlers wanting to set point or mark themselves.
(
when
desktop-buffer-point
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment