From: teranisi Date: Wed, 16 Feb 2005 14:35:16 +0000 (+0000) Subject: 2005-02-16 Yuuichi Teranishi X-Git-Tag: wl-2_14-root~43 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=05f2ccf81cbb57ac93754382ba68e4cafa4c45a8;p=elisp%2Fwanderlust.git 2005-02-16 Yuuichi Teranishi * elmo-dop.el (elmo-folder-delete-messages-dop): Delete 'Append' queue. (elmo-folder-next-message-number-dop): Return appropriate negative integer. 2005-02-15 Yoichi NAKAYAMA * elmo-dop.el (elmo-dop-queue-flush): Remove files in dop spool on clearing pending operations. (elmo-folder-next-message-number-dop): Return appropriate negative integer. --- diff --git a/elmo/ChangeLog b/elmo/ChangeLog index cd7a1e9..52051c3 100644 --- a/elmo/ChangeLog +++ b/elmo/ChangeLog @@ -1,3 +1,16 @@ +2005-02-16 Yuuichi Teranishi + + * elmo-dop.el (elmo-folder-delete-messages-dop): Delete 'Append' queue. + (elmo-folder-next-message-number-dop): Return appropriate negative + integer. + +2005-02-15 Yoichi NAKAYAMA + + * elmo-dop.el (elmo-dop-queue-flush): Remove files in dop spool on + clearing pending operations. + (elmo-folder-next-message-number-dop): Return appropriate negative + integer. + 2005-02-12 Hiroya Murata * elmo.el (toplevel): Added autoload setting for `md5'. diff --git a/elmo/elmo-dop.el b/elmo/elmo-dop.el index fcd6015..ad9847d 100644 --- a/elmo/elmo-dop.el +++ b/elmo/elmo-dop.el @@ -157,6 +157,12 @@ Saved queue is old version(2.6). Clear all pending operations? ") (not elmo-dop-flush-confirm) t) (progn (while queue + (when (string= (elmo-dop-queue-method-name (car queue)) + "Append") + (elmo-folder-delete-messages + (elmo-dop-spool-folder + (elmo-make-folder (elmo-dop-queue-fname (car queue)))) + (list (nth 1 (elmo-dop-queue-arguments (car queue)))))) (setq elmo-dop-queue (delq (car queue) elmo-dop-queue)) (setq queue (cdr queue))) (message "Pending operations are cleared.") @@ -247,8 +253,18 @@ FOLDER is the folder structure." queue) (dolist (number numbers) (if (< number 0) - (elmo-folder-delete-messages spool-folder - (list (abs number))) ; delete from queue + (progn + ;; delete from queue + (elmo-folder-delete-messages spool-folder + (list (abs number))) + (dolist (queue elmo-dop-queue) + (when (and (eq (elmo-dop-queue-fname queue) + (elmo-folder-name-internal folder)) + (eq (elmo-dop-queue-method queue) + 'elmo-folder-append-buffer-dop-delayed) + (eq (abs number) + (nth 1 (elmo-dop-queue-arguments queue)))) + (setq elmo-dop-queue (delq queue elmo-dop-queue))))) (setq queue (cons number queue)))) (when queue (elmo-dop-queue-append folder 'elmo-folder-delete-messages-dop-delayed @@ -311,15 +327,10 @@ FOLDER is the folder structure." (cons (+ max-num spool-length) (+ (length number-list) spool-length)))) (defun elmo-folder-next-message-number-dop (folder) - (let ((number-list (elmo-folder-list-messages folder nil 'in-msgdb)) - (spool-folder (elmo-dop-spool-folder folder)) - spool-length - max-num) - (setq spool-length (or (if (elmo-folder-exists-p spool-folder) - (car (elmo-folder-status spool-folder))) - 0)) - (setq max-num (if number-list (apply #'max number-list) 0)) - (+ max-num spool-length))) + (let ((spool-folder (elmo-dop-spool-folder folder))) + (- (+ 1 (elmo-max-of-list (or (elmo-folder-list-messages + spool-folder) + '(0))))))) ;;; Delayed operation (executed at online status). (defun elmo-folder-append-buffer-dop-delayed (folder flag number set-number)