aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman2005-01-30 11:07:54 +0000
committerRichard M. Stallman2005-01-30 11:07:54 +0000
commit97733c3d0022f9b1616fca7782eb927fcc72c5c4 (patch)
treee2733cdd51820c66f83cede97ba906f32a0eeb2e
parent6de38aa35015ed6fb3613eec6a37e9a2d5ec7272 (diff)
downloademacs-97733c3d0022f9b1616fca7782eb927fcc72c5c4.tar.gz
emacs-97733c3d0022f9b1616fca7782eb927fcc72c5c4.zip
(custom-bury-buffer): Function deleted.
(custom-buffer-done-function): Option deleted. (custom-buffer-done-kill): New (replacement option. (Custom-buffer-done): Call quit-window. (custom-buffer-create-internal): Update for above changes.
-rw-r--r--lisp/cus-edit.el31
1 files changed, 9 insertions, 22 deletions
diff --git a/lisp/cus-edit.el b/lisp/cus-edit.el
index 989a9f16840..30d831ff039 100644
--- a/lisp/cus-edit.el
+++ b/lisp/cus-edit.el
@@ -1180,19 +1180,10 @@ links: groups have links to subgroups."
1180 (const links)) 1180 (const links))
1181 :group 'custom-buffer) 1181 :group 'custom-buffer)
1182 1182
1183;; If we pass BUFFER to `bury-buffer', the buffer isn't removed from 1183(defcustom custom-buffer-done-kill nil
1184;; the window. 1184 "*Non-nil means exiting a Custom buffer should kill it."
1185(defun custom-bury-buffer (buffer) 1185 :type 'boolean
1186 (with-current-buffer buffer 1186 :version "21.4"
1187 (bury-buffer)))
1188
1189(defcustom custom-buffer-done-function 'custom-bury-buffer
1190 "*Function called to remove a Custom buffer when the user is done with it.
1191Called with one argument, the buffer to remove."
1192 :type '(choice (function-item :tag "Bury buffer" custom-bury-buffer)
1193 (function-item :tag "Kill buffer" kill-buffer)
1194 (function :tag "Other"))
1195 :version "21.1"
1196 :group 'custom-buffer) 1187 :group 'custom-buffer)
1197 1188
1198(defcustom custom-buffer-indent 3 1189(defcustom custom-buffer-indent 3
@@ -1262,9 +1253,9 @@ This button will have a menu with all three reset operations."
1262 :group 'custom-buffer) 1253 :group 'custom-buffer)
1263 1254
1264(defun Custom-buffer-done (&rest ignore) 1255(defun Custom-buffer-done (&rest ignore)
1265 "Remove current buffer by calling `custom-buffer-done-function'." 1256 "Exit current Custom buffer according to `custom-buffer-done-kill'."
1266 (interactive) 1257 (interactive)
1267 (funcall custom-buffer-done-function (current-buffer))) 1258 (quit-window custom-buffer-done-kill))
1268 1259
1269(defcustom custom-raised-buttons (not (equal (face-valid-attribute-values :box) 1260(defcustom custom-raised-buttons (not (equal (face-valid-attribute-values :box)
1270 '(("unspecified" . unspecified)))) 1261 '(("unspecified" . unspecified))))
@@ -1350,13 +1341,9 @@ Un-customize all values in this buffer. They get their standard settings."
1350 :tag "Finish" 1341 :tag "Finish"
1351 :help-echo 1342 :help-echo
1352 (lambda (&rest ignore) 1343 (lambda (&rest ignore)
1353 (cond 1344 (if custom-buffer-done-kill
1354 ((eq custom-buffer-done-function 1345 "Kill this buffer"
1355 'custom-bury-buffer) 1346 "Bury this buffer"))
1356 "Bury this buffer")
1357 ((eq custom-buffer-done-function 'kill-buffer)
1358 "Kill this buffer")
1359 (t "Finish with this buffer")))
1360 :action #'Custom-buffer-done) 1347 :action #'Custom-buffer-done)
1361 (widget-insert "\n\n") 1348 (widget-insert "\n\n")
1362 (message "Creating customization items...") 1349 (message "Creating customization items...")