aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/cus-edit.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/cus-edit.el')
-rw-r--r--lisp/cus-edit.el10
1 files changed, 7 insertions, 3 deletions
diff --git a/lisp/cus-edit.el b/lisp/cus-edit.el
index 15f43080aff..609b5572a08 100644
--- a/lisp/cus-edit.el
+++ b/lisp/cus-edit.el
@@ -4435,9 +4435,8 @@ The format is suitable for use with `easy-menu-define'."
4435 ;; Actually, this misfeature of dense keymaps was fixed on 2001-11-26. 4435 ;; Actually, this misfeature of dense keymaps was fixed on 2001-11-26.
4436 (let ((map (make-keymap))) 4436 (let ((map (make-keymap)))
4437 (set-keymap-parent map widget-keymap) 4437 (set-keymap-parent map widget-keymap)
4438 (define-key map [remap self-insert-command] 4438 (define-key map [remap self-insert-command] 'custom-no-edit)
4439 'custom-no-edit) 4439 (define-key map "\^m" 'custom-newline)
4440 (define-key map "\^m" 'custom-no-edit)
4441 (define-key map " " 'scroll-up) 4440 (define-key map " " 'scroll-up)
4442 (define-key map "\177" 'scroll-down) 4441 (define-key map "\177" 'scroll-down)
4443 (define-key map "\C-c\C-c" 'Custom-set) 4442 (define-key map "\C-c\C-c" 'Custom-set)
@@ -4452,6 +4451,11 @@ The format is suitable for use with `easy-menu-define'."
4452(defun custom-no-edit (pos &optional event) 4451(defun custom-no-edit (pos &optional event)
4453 "Invoke button at POS, or refuse to allow editing of Custom buffer." 4452 "Invoke button at POS, or refuse to allow editing of Custom buffer."
4454 (interactive "@d") 4453 (interactive "@d")
4454 (error "You can't edit this part of the Custom buffer"))
4455
4456(defun custom-newline (pos &optional event)
4457 "Invoke button at POS, or refuse to allow editing of Custom buffer."
4458 (interactive "@d")
4455 (let ((button (get-char-property pos 'button))) 4459 (let ((button (get-char-property pos 'button)))
4456 (if button 4460 (if button
4457 (widget-apply-action button event) 4461 (widget-apply-action button event)