summaryrefslogtreecommitdiff
path: root/lisp/desktop.el
diff options
context:
space:
mode:
authorMiles Bader <miles@gnu.org>2007-10-30 23:28:12 +0000
committerMiles Bader <miles@gnu.org>2007-10-30 23:28:12 +0000
commitba69b876ac836a88877dab99e6fc2352dd36c855 (patch)
treeea26f4dfdee15465752767ec150b509aae48f52e /lisp/desktop.el
parent904fac674eb51808091bed8f7c608745e0dfc0b8 (diff)
parent93c5a976a01b25f96bb135086d8fcd3a869b3fb9 (diff)
downloademacs-ba69b876ac836a88877dab99e6fc2352dd36c855.tar.gz
Merge from emacs--rel--22
Patches applied: * emacs--rel--22 (patch 138-139) - Update from CVS Revision: emacs@sv.gnu.org/emacs--devo--0--patch-914
Diffstat (limited to 'lisp/desktop.el')
-rw-r--r--lisp/desktop.el8
1 files changed, 6 insertions, 2 deletions
diff --git a/lisp/desktop.el b/lisp/desktop.el
index 040688492a4..4707904b28b 100644
--- a/lisp/desktop.el
+++ b/lisp/desktop.el
@@ -135,6 +135,8 @@
;;; Code:
+(defvar uniquify-managed)
+
(defvar desktop-file-version "206"
"Version number of desktop file format.
Written into the desktop file and used at desktop read to provide
@@ -654,7 +656,9 @@ is nil, ask the user where to save the desktop."
(list
;; basic information
(desktop-file-name (buffer-file-name) desktop-dirname)
- (buffer-name)
+ (if (bound-and-true-p uniquify-managed)
+ (uniquify-item-base (car uniquify-managed))
+ (buffer-name))
major-mode
;; minor modes
(let (ret)
@@ -1150,7 +1154,7 @@ directory DIRNAME."
(setq desktop-first-buffer result))
(set-buffer result)
(unless (equal (buffer-name) desktop-buffer-name)
- (rename-buffer desktop-buffer-name))
+ (rename-buffer desktop-buffer-name t))
;; minor modes
(cond ((equal '(t) desktop-buffer-minor-modes) ; backwards compatible
(auto-fill-mode 1))