aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman1995-04-06 20:05:39 +0000
committerRichard M. Stallman1995-04-06 20:05:39 +0000
commitf4c73d078fcd8eaaac8e6fbc43592d667ef15663 (patch)
tree385def85a9963035f496feb76a457902d76243ee
parenta4888c88820a17b49586ff6a782769501d9439d3 (diff)
downloademacs-f4c73d078fcd8eaaac8e6fbc43592d667ef15663.tar.gz
emacs-f4c73d078fcd8eaaac8e6fbc43592d667ef15663.zip
(desktop-save): Use dired-directory as name
of top-level in order to capture wildcards used. (desktop-buffer-dired): Skip possible wildcard when checking for directory existance. Use dired-insert-subdir, not dired-maybe-insert-subdir.
-rw-r--r--lisp/desktop.el24
1 files changed, 13 insertions, 11 deletions
diff --git a/lisp/desktop.el b/lisp/desktop.el
index a214a36ead8..b9787a83766 100644
--- a/lisp/desktop.el
+++ b/lisp/desktop.el
@@ -1,9 +1,9 @@
1;;; desktop.el --- save partial status of Emacs when killed 1;;; desktop.el --- save partial status of Emacs when killed
2 2
3;; Copyright (C) 1993, 1994 Free Software Foundation, Inc. 3;; Copyright (C) 1993, 1994, 1995 Free Software Foundation, Inc.
4 4
5;; Author: Morten Welinder <terra@diku.dk> 5;; Author: Morten Welinder <terra@diku.dk>
6;; Version: 2.09 6;; Version: 2.10
7;; Keywords: customization 7;; Keywords: customization
8;; Favourite-brand-of-beer: None, I hate beer. 8;; Favourite-brand-of-beer: None, I hate beer.
9 9
@@ -50,7 +50,7 @@
50;; 50;;
51;; (setq desktop-locals-to-save (cons 'foobar desktop-locals-to-save)) 51;; (setq desktop-locals-to-save (cons 'foobar desktop-locals-to-save))
52;; 52;;
53;; To avoid saving excessive amounts of data you may also with to add 53;; To avoid saving excessive amounts of data you may also wish to add
54;; something like the following 54;; something like the following
55;; 55;;
56;; (add-hook 'kill-emacs-hook 56;; (add-hook 'kill-emacs-hook
@@ -84,7 +84,7 @@
84;; chris@tecc.co.uk (Chris Boucher) for a mark tip. 84;; chris@tecc.co.uk (Chris Boucher) for a mark tip.
85;; f89-kam@nada.kth.se (Klas Mellbourn) for a mh-e tip. 85;; f89-kam@nada.kth.se (Klas Mellbourn) for a mh-e tip.
86;; kifer@sbkifer.cs.sunysb.edu (M. Kifer) for a bug hunt. 86;; kifer@sbkifer.cs.sunysb.edu (M. Kifer) for a bug hunt.
87;; treese@lcs.mit.edu (Win Treese) for ange-ftp ftps. 87;; treese@lcs.mit.edu (Win Treese) for ange-ftp tips.
88;; --------------------------------------------------------------------------- 88;; ---------------------------------------------------------------------------
89;; TODO: 89;; TODO:
90;; 90;;
@@ -358,11 +358,13 @@ MODE is the major mode."
358 (list Info-current-file 358 (list Info-current-file
359 Info-current-node)) 359 Info-current-node))
360 ((eq major-mode 'dired-mode) 360 ((eq major-mode 'dired-mode)
361 (nreverse 361 (cons
362 (mapcar 362 (expand-file-name dired-directory)
363 (function car) 363 (cdr
364 dired-subdir-alist))) 364 (nreverse
365 ) 365 (mapcar
366 (function car)
367 dired-subdir-alist))))))
366 (let ((locals desktop-locals-to-save) 368 (let ((locals desktop-locals-to-save)
367 (loclist (buffer-local-variables)) 369 (loclist (buffer-local-variables))
368 (ll)) 370 (ll))
@@ -470,10 +472,10 @@ to provide correct modes for autoloaded files."
470;; ---------------------------------------------------------------------------- 472;; ----------------------------------------------------------------------------
471(defun desktop-buffer-dired () "Load a directory using dired." 473(defun desktop-buffer-dired () "Load a directory using dired."
472 (if (eq 'dired-mode mam) 474 (if (eq 'dired-mode mam)
473 (if (file-directory-p (directory-file-name (car misc))) 475 (if (file-directory-p (file-name-directory (car misc)))
474 (progn 476 (progn
475 (dired (car misc)) 477 (dired (car misc))
476 (mapcar (function dired-maybe-insert-subdir) (cdr misc)) 478 (mapcar 'dired-insert-subdir (cdr misc))
477 t) 479 t)
478 (message "Directory %s no longer exists." (car misc)) 480 (message "Directory %s no longer exists." (car misc))
479 (sit-for 1) 481 (sit-for 1)