(wl-summary-test-spam-region): New function.
authorokazaki <okazaki>
Thu, 2 Jun 2005 07:49:13 +0000 (07:49 +0000)
committerokazaki <okazaki>
Thu, 2 Jun 2005 07:49:13 +0000 (07:49 +0000)
(wl-spam-setup): Bind "rkc".

wl/ChangeLog
wl/wl-spam.el

index 57e3ff2..7580c38 100644 (file)
@@ -1,3 +1,8 @@
+2005-06-02  Tetsurou Okazaki  <okazaki@be.to>
+
+       * wl-spam.el (wl-summary-test-spam-region): New function.
+       (wl-spam-setup): Bind "rkc".
+
 2005-05-10  Yoichi NAKAYAMA  <yoichi@geiin.org>
 
        * wl-fldmgr.el (wl-fldmgr-add): Undo the last change.
index 6f549ff..3d0b0be 100644 (file)
@@ -190,6 +190,16 @@ See `wl-summary-mark-action-list' for the detail of element."
     (when (interactive-p)
       (message "No: %d is %sa spam message." number (if spam "" "not ")))))
 
+(defun wl-summary-test-spam-region (beg end)
+  (interactive "r")
+  (let ((numbers (wl-summary-collect-numbers-region beg end)))
+    (cond (numbers
+          (wl-spam-map-spam-messages wl-summary-buffer-elmo-folder
+                                     numbers
+                                     #'wl-summary-spam))
+         ((interactive-p)
+          (message "No message to test.")))))
+
 (defun wl-summary-mark-spam (&optional all)
   "Set spam mark to messages which is spam classification."
   (interactive "P")
@@ -354,6 +364,8 @@ See `wl-summary-mark-action-list' for the detail of element."
                  wl-summary-skip-mark-list))))
   (define-key wl-summary-mode-map "k" wl-summary-spam-map)
   (define-key
+    wl-summary-mode-map "rkc" 'wl-summary-test-spam-region)
+  (define-key
     wl-summary-mode-map "mk" 'wl-summary-target-mark-spam)
   (define-key
     wl-summary-mode-map "ms" 'wl-summary-target-mark-register-as-spam)