+2004-06-11 Luc Teirlinck <teirllm@auburn.edu>
+
+ * dired.el (dired-revert): If buffer is marked unmodified before
+ reverting, keep it marked unmodified.
+ Adapt to new conventions for commenting out code.
+ (dired-make-relative): Adapt to new conventions for commenting out
+ code.
+
2004-06-10 Miles Bader <miles@gnu.ai.mit.edu>
* eshell/esh-module.el (eshell-load-defgroups): Bind
Should not fail even on completely garbaged buffers.
Preserves old cursor, marks/flags, hidden-p."
(widen) ; just in case user narrowed
- (let ((opoint (point))
+ (let ((modflag (buffer-modified-p))
+ (opoint (point))
(ofile (dired-get-filename nil t))
(mark-alist nil) ; save marked files
(hidden-subdirs (dired-remember-hidden))
(save-excursion ; hide subdirs that were hidden
(dolist (dir hidden-subdirs)
(if (dired-goto-subdir dir)
- (dired-hide-subdir 1)))))
+ (dired-hide-subdir 1))))
+ (unless modflag (restore-buffer-modified-p nil)))
;; outside of the let scope
-;;; Might as well not override the user if the user changed this.
+;;; Might as well not override the user if the user changed this.
;;; (setq buffer-read-only t)
)
(setq dir (expand-file-name dir)))
(if (string-match (concat "^" (regexp-quote dir)) file)
(substring file (match-end 0))
-;;; (or no-error
+;;; (or no-error
;;; (error "%s: not in directory tree growing at %s" file dir))
file))
\f