+2008-02-14 Juanma Barranquero <lekktu@gmail.com>
+
+ * uniquify.el (uniquify-buffer-base-name): New function.
+ Suggested by Stefan Monnier <monnier@iro.umontreal.ca>.
+
+ * desktop.el (uniquify-managed): Don't defvar.
+ (desktop-buffer-info): Use `uniquify-buffer-base-name', not
+ `uniquify-managed'. Return also the buffer's base name.
+ (desktop-save): When saving the buffer info, filter out the base name,
+ and save it as buffer name if the buffer is managed by uniquify.
+ (uniquify-item-base): Don't declare; not called anymore.
+
2008-02-14 Dan Nicolaescu <dann@ics.uci.edu>
* vc.el (vc-annotate-find-revision-at-line): New function.
* Makefile.in (custom-deps, finder-data, autoloads, recompile):
Remove `LC_ALL=C', since it's included in $(emacs) now.
-2008-02-14 Zhang Wei <id.brep@gmail.com>
+2008-02-14 Zhang Wei <id.brep@gmail.com>
* textmodes/org-publish.el (org-publish-timestamp-filename):
Replace colon characters in filename too.
2008-02-14 Mark A. Hershberger <mah@everybody.org>
- * progmodes/flymake.el (flymake-allowed-file-name-masks): Add
- support for .pm files and .php files.
+ * progmodes/flymake.el (flymake-allowed-file-name-masks):
+ Add support for .pm files and .php files.
(flymake-err-line-patterns): Add pattern for PHP errors.
(flymake-php-init): New function. PHP support for flymake.
- * progmodes/compile.el (compilation-error-regexp-alist-alist): Add
- regular expression for PHP errors.
-
+ * progmodes/compile.el (compilation-error-regexp-alist-alist):
+ Add regular expression for PHP errors.
2008-02-13 Michael Albinus <michael.albinus@gmx.de>
- * net/ange-ftp.el (ange-ftp-quote-string): Use
- `shell-quote-argument'. This DTRT even on w32 machines.
+ * net/ange-ftp.el (ange-ftp-quote-string): Use `shell-quote-argument'.
+ This DTRT even on w32 machines.
(ange-ftp-cf1): Quote FILENAME.
2008-02-13 Stefan Monnier <monnier@iro.umontreal.ca>
;;; 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
value)))
;; ----------------------------------------------------------------------------
-(declare-function uniquify-item-base "uniquify" (cl-x) t) ; defstruct
-
(defun desktop-buffer-info (buffer)
(set-buffer buffer)
(list
+ ;; base name of the buffer; replaces the buffer name if managed by uniquify
+ (and (fboundp 'uniquify-buffer-base-name) (uniquify-buffer-base-name))
;; basic information
(desktop-file-name (buffer-file-name) desktop-dirname)
- (if (bound-and-true-p uniquify-managed)
- (uniquify-item-base (car uniquify-managed))
- (buffer-name))
+ (buffer-name)
major-mode
;; minor modes
(let (ret)
(insert "\n;; Buffer section -- buffers listed in same order as in buffer list:\n")
(dolist (l (mapcar 'desktop-buffer-info (buffer-list)))
- (when (apply 'desktop-save-buffer-p l)
- (insert "("
- (if (or (not (integerp eager))
- (if (zerop eager)
- nil
- (setq eager (1- eager))))
- "desktop-create-buffer"
- "desktop-append-buffer-args")
- " "
- desktop-file-version)
- (dolist (e l)
- (insert "\n " (desktop-value-to-string e)))
- (insert ")\n\n")))
+ (let ((base (pop l)))
+ (when (apply 'desktop-save-buffer-p l)
+ (insert "("
+ (if (or (not (integerp eager))
+ (if (zerop eager)
+ nil
+ (setq eager (1- eager))))
+ "desktop-create-buffer"
+ "desktop-append-buffer-args")
+ " "
+ desktop-file-version)
+ ;; If the base name is non-nil, we save it instead of the buffer name
+ (when base (setcar (nthcdr 1 l) base))
+ (dolist (e l)
+ (insert "\n " (desktop-value-to-string e)))
+ (insert ")\n\n"))))
(setq default-directory desktop-dirname)
(let ((coding-system-for-write 'emacs-mule))