changeset 36715:2b98ff02ebaf

(tool-bar-setup): Don't suppress write-file and save-buffer if buffer-file-name non-nil. From rms.
author Dave Love <fx@gnu.org>
date Sat, 10 Mar 2001 13:20:25 +0000
parents 60af090908e9
children a563ead0ab5f
files lisp/toolbar/tool-bar.el
diffstat 1 files changed, 8 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/toolbar/tool-bar.el	Sat Mar 10 10:58:23 2001 +0000
+++ b/lisp/toolbar/tool-bar.el	Sat Mar 10 13:20:25 2001 +0000
@@ -175,11 +175,15 @@
   (tool-bar-add-item-from-menu 'dired "open")
   (tool-bar-add-item-from-menu 'kill-this-buffer "close")
   (tool-bar-add-item-from-menu 'save-buffer "save" nil
-			       :visible '(not (eq 'special (get major-mode
-								'mode-class))))
+			       :visible '(or buffer-file-name
+					     (not (eq 'special
+						      (get major-mode
+							   'mode-class)))))
   (tool-bar-add-item-from-menu 'write-file "saveas" nil
-			       :visible '(not (eq 'special (get major-mode
-								'mode-class))))
+			       :visible '(or buffer-file-name
+					     (not (eq 'special
+						      (get major-mode
+							   'mode-class)))))
   (tool-bar-add-item-from-menu 'undo "undo" nil
 			       :visible '(not (eq 'special (get major-mode
 								'mode-class))))