From 3b99395034f8773fde1d868427be59d728d60344 Mon Sep 17 00:00:00 2001 From: hmurata Date: Mon, 20 Oct 2003 08:39:17 +0000 Subject: [PATCH] * wl-refile.el (wl-refile-guess): Added second argument `functions'. * wl-action.el (wl-auto-refile-guess-functions): New variable. (wl-summary-auto-refile): Call wl-refile-guess with wl-auto-refile-guess-functions instead of wl-refile-guess-by-rule. --- wl/ChangeLog | 8 ++++++++ wl/wl-action.el | 9 +++++++-- wl/wl-refile.el | 5 +++-- 3 files changed, 18 insertions(+), 4 deletions(-) diff --git a/wl/ChangeLog b/wl/ChangeLog index 2a522e1..16ff9e0 100644 --- a/wl/ChangeLog +++ b/wl/ChangeLog @@ -1,3 +1,11 @@ +2003-10-20 Hiroya Murata + + * wl-refile.el (wl-refile-guess): Added second argument `functions'. + + * wl-action.el (wl-auto-refile-guess-functions): New variable. + (wl-summary-auto-refile): Call wl-refile-guess with + wl-auto-refile-guess-functions instead of wl-refile-guess-by-rule. + 2003-10-17 Hiroya Murata * wl-summary.el (wl-summary-pack-number): Call wl-summary-rescan diff --git a/wl/wl-action.el b/wl/wl-action.el index ea4bf58..f4007da 100644 --- a/wl/wl-action.el +++ b/wl/wl-action.el @@ -791,6 +791,10 @@ Return number if put mark succeed" (member (wl-summary-message-mark wl-summary-buffer-elmo-folder number) wl-summary-auto-refile-skip-marks)) +(defvar wl-auto-refile-guess-functions + '(wl-refile-guess-by-rule) + "*List of functions which is used for guessing refile destination folder.") + (defun wl-summary-auto-refile (&optional open-all) "Set refile mark automatically according to 'wl-refile-guess-by-rule'." (interactive "P") @@ -818,9 +822,10 @@ Return number if put mark succeed" number)) (setq dst (wl-folder-get-realname - (wl-refile-guess-by-rule + (wl-refile-guess (elmo-message-entity wl-summary-buffer-elmo-folder - number)))) + number) + wl-auto-refile-guess-functions))) (not (equal dst spec)) (let ((pair (assoc dst checked-dsts)) ret) diff --git a/wl/wl-refile.el b/wl/wl-refile.el index 607e410..6a294ad 100644 --- a/wl/wl-refile.el +++ b/wl/wl-refile.el @@ -155,8 +155,9 @@ (elmo-define-obsolete-variable 'wl-refile-guess-func-list 'wl-refile-guess-functions) -(defun wl-refile-guess (entity) - (let ((flist wl-refile-guess-functions) guess) +(defun wl-refile-guess (entity &optional functions) + (let ((flist (or functions wl-refile-guess-functions)) + guess) (while flist (if (setq guess (funcall (car flist) entity)) (setq flist nil) -- 1.7.10.4