From: teranisi Date: Mon, 21 Jul 2003 14:47:42 +0000 (+0000) Subject: * wl-score.el (wl-score-get-latest-msgs): Don't use msgdb directly. X-Git-Tag: elmo-mark-restart~14 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e892c13f69f3fc397f84c74ab739c0f978f06356;p=elisp%2Fwanderlust.git * wl-score.el (wl-score-get-latest-msgs): Don't use msgdb directly. (wl-summary-rescore): Ditto. --- diff --git a/wl/ChangeLog b/wl/ChangeLog index 0294ad5..c0b881d 100644 --- a/wl/ChangeLog +++ b/wl/ChangeLog @@ -4,6 +4,8 @@ directly. (wl-score-overview-entity-get-lines): Ditto. (wl-score-overview-entity-get-xref): Ditto. + (wl-score-get-latest-msgs): Ditto. + (wl-summary-rescore): Ditto. * wl-summary.el (wl-summary-mode-map): Bind wl-summary-mark-as-answered to "&". diff --git a/wl/wl-score.el b/wl/wl-score.el index aeb8834..c7bd221 100644 --- a/wl/wl-score.el +++ b/wl/wl-score.el @@ -438,7 +438,7 @@ Set `wl-score-cache' nil." (while wl-scores-messages (when (or (/= wl-summary-default-score (cdar wl-scores-messages))) - (setq num (elmo-msgdb-overview-entity-get-number + (setq num (elmo-message-entity-number (caar wl-scores-messages)) score (cdar wl-scores-messages)) (if (setq entry (assq num wl-summary-scored)) @@ -921,22 +921,23 @@ Set `wl-score-cache' nil." (let* ((now (wl-day-number (current-time-string))) (expire (and wl-score-expiry-days (- now wl-score-expiry-days))) - (roverview (reverse (elmo-msgdb-get-overview - (wl-summary-buffer-msgdb)))) + (rnumbers (reverse wl-summary-buffer-number-list)) msgs) (if (not expire) (elmo-folder-list-messages wl-summary-buffer-elmo-folder nil t) - ;; XXX What's this? (catch 'break - (while roverview + (while rnumbers (if (< (wl-day-number - (elmo-msgdb-overview-entity-get-date (car roverview))) + (elmo-message-entity-field + (elmo-message-entity wl-summary-buffer-elmo-folder + (car rnumbers)) + 'date)) expire) (throw 'break t)) - (wl-push (elmo-msgdb-overview-entity-get-number (car roverview)) - msgs) - (setq roverview (cdr roverview)))) + + (wl-push (car rnumbers)) + (setq rnumbers (cdr rnumbers)))) msgs))) (defun wl-score-get-header (header &optional extra) @@ -1175,9 +1176,10 @@ Set `wl-score-cache' nil." (wl-score-save) (setq wl-score-cache nil) (setq wl-summary-scored nil) - (setq number-alist (elmo-msgdb-get-number-alist (wl-summary-buffer-msgdb))) (wl-summary-score-headers (unless arg - (wl-summary-rescore-msgs number-alist))) + (wl-summary-rescore-msgs + (elmo-folder-list-messages + wl-summary-buffer-elmo-folder t t)))) (setq expunged (wl-summary-score-update-all-lines t)) (if expunged (message "%d message(s) are expunged by scoring." (length expunged)))