From: Juanma Barranquero Date: Tue, 12 Feb 2008 14:32:56 +0000 (+0000) Subject: (uniquify-buffer-base-name): New function. X-Git-Tag: emacs-pretest-22.1.91~32 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=c91db6f12d39ea9b4abeffcebf185b1779562187;p=emacs.git (uniquify-buffer-base-name): New function. Suggested by Stefan Monnier . --- diff --git a/lisp/uniquify.el b/lisp/uniquify.el index 02f598ae9fc..b2167f48656 100644 --- a/lisp/uniquify.el +++ b/lisp/uniquify.el @@ -189,6 +189,13 @@ It actually holds the list of `uniquify-item's corresponding to the conflict.") (make-variable-buffer-local 'uniquify-managed) (put 'uniquify-managed 'permanent-local t) +;; Used in desktop.el to save the non-uniquified buffer name +(defun uniquify-buffer-base-name () + "Return the base name of the current buffer. +Return nil if the buffer is not managed by uniquify." + (and uniquify-managed + (uniquify-item-base (car uniquify-managed)))) + ;;; Main entry point. (defun uniquify-rationalize-file-buffer-names (base dirname newbuf) @@ -489,7 +496,7 @@ For use on `kill-buffer-hook'." (dolist (buf buffers) (set-buffer (car buf)) (rename-buffer (cdr buf) t)))) - ;; continue standard uploading + ;; continue standard unloading nil) (provide 'uniquify)