From: hmurata Date: Sun, 7 Sep 2003 14:35:48 +0000 (+0000) Subject: * elmo-msgdb.el (elmo-msgdb-delete-messages): Renamed from X-Git-Tag: wl-2_11_11~4 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=21f27bac7391dd60d5e54c2c4c5ef1e7b5557a54;p=elisp%2Fwanderlust.git * elmo-msgdb.el (elmo-msgdb-delete-messages): Renamed from `elmo-msgdb-delete-msgs'. * elmo.el (elmo-folder-count-flags): Don't use `elmo-msgdb-get-mark-alist'. (elmo-folder-detach-messages): Follow the API change. --- diff --git a/elmo/ChangeLog b/elmo/ChangeLog index 878be7f..2531315 100644 --- a/elmo/ChangeLog +++ b/elmo/ChangeLog @@ -1,5 +1,12 @@ 2003-09-07 Hiroya Murata + * elmo-msgdb.el (elmo-msgdb-delete-messages): Renamed from + `elmo-msgdb-delete-msgs'. + + * elmo.el (elmo-folder-count-flags): Don't use + `elmo-msgdb-get-mark-alist'. + (elmo-folder-detach-messages): Follow the API change. + * elmo.el (elmo-folder-list-messages): Append killed messages into result if `visible-only' is nil. diff --git a/elmo/elmo-msgdb.el b/elmo/elmo-msgdb.el index 3422a01..17d46b4 100644 --- a/elmo/elmo-msgdb.el +++ b/elmo/elmo-msgdb.el @@ -88,7 +88,7 @@ ;; FIELD-VALUE elmo-msgdb-get-field MSGDB NUMBER FIELD ;; MSGDB elmo-msgdb-append MSGDB MSGDB-APPEND ;; MSGDB elmo-msgdb-clear MSGDB -;; elmo-msgdb-delete-msgs MSGDB NUMBERS +;; elmo-msgdb-delete-messages MSGDB NUMBERS ;; elmo-msgdb-sort-by-date MSGDB ;;; @@ -488,7 +488,7 @@ FLAG is a symbol which is one of the following: msgdb) (elmo-make-msgdb))) -(defun elmo-msgdb-delete-msgs (msgdb msgs) +(defun elmo-msgdb-delete-messages (msgdb msgs) "Delete MSGS from MSGDB content of MSGDB is changed." (let* ((overview (car msgdb)) diff --git a/elmo/elmo.el b/elmo/elmo.el index 243194e..b1fb544 100644 --- a/elmo/elmo.el +++ b/elmo/elmo.el @@ -1213,14 +1213,16 @@ Return a list of numbers (`new' `unread' `answered')") (luna-define-method elmo-folder-count-flags ((folder elmo-folder)) (let ((new 0) (unreads 0) - (answered 0)) - (dolist (elem (elmo-msgdb-get-mark-alist (elmo-folder-msgdb folder))) + (answered 0) + flags) + (dolist (number (elmo-folder-list-messages folder 'visible 'in-msgdb)) + (setq flags (elmo-message-flags folder number)) (cond - ((string= (cadr elem) elmo-msgdb-new-mark) + ((memq 'new flags) (incf new)) - ((member (cadr elem) (elmo-msgdb-unread-marks)) + ((memq 'unread flags) (incf unreads)) - ((member (cadr elem) (elmo-msgdb-answered-marks)) + ((memq 'answered flags) (incf answered)))) (list new unreads answered))) @@ -1577,7 +1579,7 @@ If update process is interrupted, return nil.") (luna-define-method elmo-folder-detach-messages ((folder elmo-folder) numbers) - (elmo-msgdb-delete-msgs (elmo-folder-msgdb folder) numbers)) + (elmo-msgdb-delete-messages (elmo-folder-msgdb folder) numbers)) (luna-define-generic elmo-folder-length (folder) "Return number of messages in the FOLDER.")