]> git.eshelyaron.com Git - emacs.git/commitdiff
(desktop-read): Run `desktop-not-loaded-hook' in the directory
authorJuanma Barranquero <lekktu@gmail.com>
Wed, 20 Jun 2007 10:12:44 +0000 (10:12 +0000)
committerJuanma Barranquero <lekktu@gmail.com>
Wed, 20 Jun 2007 10:12:44 +0000 (10:12 +0000)
where the desktop file was found, as the docstring says.
(desktop-kill): Use `read-directory-name'.

lisp/ChangeLog
lisp/desktop.el

index 0e0631a07ce9cda6beb7615dd8a54b3dbbb1614f..f644b3551378088c33ab7c7506f21fc0aa56705a 100644 (file)
@@ -1,9 +1,15 @@
+2007-06-20  Juanma Barranquero  <lekktu@gmail.com>
+
+       * desktop.el (desktop-read): Run `desktop-not-loaded-hook' in the
+       directory where the desktop file was found, as the docstring says.
+       (desktop-kill): Use `read-directory-name'.
+
 2007-06-20  Alan Mackenzie  <acm@muc.de>
 
        * progmodes/cc-mode.el (c-remove-any-local-eval-or-mode-variables):
        When removing lines, also remove the \n.  Correction of patch of
        2007-04-21.
-       
+
 2007-06-20  Martin Rudalics  <rudalics@gmx.at>
 
        * mouse.el (mouse-drag-mode-line-1): Quit mouse tracking when
        (vc-hg-register): New function.
        (vc-hg-checkout): Likewise.
 
-2007-06-20  Reto Zimmermann <reto@gnu.org>
+2007-06-20  Reto Zimmermann  <reto@gnu.org>
 
        * progmodes/vera-mode.el: New file.
 
-2007-06-19  Ivan Kanis <apple@kanis.eu>
+2007-06-19  Ivan Kanis  <apple@kanis.eu>
 
        * vc-hg.el: New file.
 
 2007-06-14  Michael Kifer  <kifer@cs.stonybrook.edu>
 
        * viper.el (viper-describe-key-ad, viper-describe-key-briefly-ad):
-       different advices for Emacs and XEmacs.  Compile them conditionally.
-       (viper-version): belated version change.
+       Different advices for Emacs and XEmacs.  Compile them conditionally.
+       (viper-version): Belated version change.
 
 2007-06-14  Juanma Barranquero  <lekktu@gmail.com>
 
        (desktop-kill): Tell `desktop-save' that this is the last save.
        Release the lock afterwards.
        (desktop-buffer-info): New function.
-       (desktop-save): Use it.  Run `desktop-save-hook' where the doc
+       (desktop-save): Use it.  Run `desktop-save-hook' where the doc
        says to.  Detect conflicts, and manage the lock.
        (desktop-read): Detect conflicts.  Manage the lock.
 
 
        * emulation/tpu-edt.el (tpu-gold-map): Rename from GOLD-map.
        (tpu-lucid-emacs-p): Remove.  Use (featurep 'xemacs) instead.
-       (CSI-map, GOLD-CSI-map, GOLD-SS3-map, SS3-map): Delete vars.
+       (CSI-map, GOLD-CSI-map, GOLD-SS3-map, SS3-map): Delete vars.
        (tpu-gold-map, tpu-global-map): Add all the SS3 and CSI bindings, using
        keysyms rather than byte sequences.
        (tpu-copy-keyfile): Don't force the user to use tpu-mapper.el.
index 191d1dbc291429831b5a27dce874bd9931574c48..e709a6394e312bb5140669462b7c29e8153a0cb2 100644 (file)
@@ -626,9 +626,7 @@ is nil, ask the user where to save the desktop."
       (setq desktop-dirname
             (file-name-as-directory
              (expand-file-name
-              (call-interactively
-               (lambda (dir)
-                 (interactive "DDirectory for desktop file: ") dir))))))
+             (read-directory-name "Directory for desktop file: " nil nil t)))))
     (condition-case err
        (desktop-save desktop-dirname t)
       (file-error
@@ -964,9 +962,9 @@ It returns t if a desktop file was loaded, nil otherwise."
                       (not (y-or-n-p (format "Warning: desktop file appears to be in use by PID %s.\n\
 Using it may cause conflicts.  Use it anyway? " owner)))))
              (progn
-               (setq desktop-dirname nil)
                (let ((default-directory desktop-dirname))
                  (run-hooks 'desktop-not-loaded-hook))
+               (setq desktop-dirname nil)
                (message "Desktop file in use; not loaded."))
            (desktop-lazy-abort)
            ;; Evaluate desktop buffer and remember when it was modified.