changeset 66172:b393a1601bc1

* gnus-cus.el (gnus-custom-map): New variable. Bind mouse-1 to widget-move-and-invoke. (gnus-custom-mode): Use gnus-custom-map.
author Chong Yidong <cyd@stupidchicken.com>
date Tue, 18 Oct 2005 00:29:41 +0000
parents 1b475d6de39b
children aec7b3bb973f
files lisp/gnus/ChangeLog lisp/gnus/gnus-cus.el
diffstat 2 files changed, 18 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/gnus/ChangeLog	Tue Oct 18 00:28:57 2005 +0000
+++ b/lisp/gnus/ChangeLog	Tue Oct 18 00:29:41 2005 +0000
@@ -1,3 +1,9 @@
+2005-10-17  Chong Yidong  <cyd@stupidchicken.com>
+
+	* gnus-cus.el (gnus-custom-map): New variable.  Bind mouse-1 to
+	widget-move-and-invoke.
+	(gnus-custom-mode): Use gnus-custom-map.
+
 2005-10-15  Bill Wohler  <wohler@newt.com>
 
 	* message.el (message-tool-bar-map): Renamed image file from
--- a/lisp/gnus/gnus-cus.el	Tue Oct 18 00:28:57 2005 +0000
+++ b/lisp/gnus/gnus-cus.el	Tue Oct 18 00:29:41 2005 +0000
@@ -36,6 +36,14 @@
 
 ;;; Widgets:
 
+(defvar gnus-custom-map
+  (let ((map (make-keymap)))
+    (set-keymap-parent map widget-keymap)
+    (suppress-keymap map)
+    (define-key map [mouse-1] 'widget-move-and-invoke)
+    map)
+  "Keymap for editing Gnus customization buffers.")
+
 (defun gnus-custom-mode ()
   "Major mode for editing Gnus customization buffers.
 
@@ -51,7 +59,7 @@
   (kill-all-local-variables)
   (setq major-mode 'gnus-custom-mode
 	mode-name "Gnus Customize")
-  (use-local-map widget-keymap)
+  (use-local-map gnus-custom-map)
   ;; Emacs 21 stuff:
   (when (and (facep 'custom-button-face)
 	     (facep 'custom-button-pressed-face))
@@ -479,7 +487,7 @@
 	    (widget-create 'sexp
 			   :tag "Method"
 			   :value (gnus-info-method info))))
-    (use-local-map widget-keymap)
+    (use-local-map gnus-custom-map)
     (widget-setup)
     (buffer-enable-undo)
     (goto-char (point-min))))
@@ -873,7 +881,7 @@
 			 '(repeat :inline t
 				  :tag "Unknown entries"
 				  sexp)))
-    (use-local-map widget-keymap)
+    (use-local-map gnus-custom-map)
     (widget-setup)))
 
 (defun gnus-score-customize-done (&rest ignore)
@@ -1050,7 +1058,7 @@
 
       (gnus-agent-cat-prepare-category-field agent-enable-undownloaded-faces)
 
-      (use-local-map widget-keymap)
+      (use-local-map gnus-custom-map)
       (widget-setup)
       (buffer-enable-undo))))