Mercurial > emacs
diff lisp/gnus/gnus-sum.el @ 111721:7bb815042e61
nnml.el, nnfolder.el, nntp.el (*-request-set-mark): Extend syntax with 'set.
nnheader.el, nntp.el, nnfolder.el, nnml.el (*-request-set-mark): Refactor out nnheader-update-marks-actions and use it throughout.
nnmaildir.el (nnmaildir-request-set-mark): Be explicit about 'set.
gnus-sum.el (gnus-summary-push-marks-to-backend): Use 'set instead of 'add and 'delete to set backend marks.
author | Katsumi Yamaoka <yamaoka@jpl.org> |
---|---|
date | Fri, 26 Nov 2010 02:11:40 +0000 |
parents | bcb41b2787e8 |
children | f97704487fb3 |
line wrap: on
line diff
--- a/lisp/gnus/gnus-sum.el Fri Nov 26 01:27:37 2010 +0000 +++ b/lisp/gnus/gnus-sum.el Fri Nov 26 02:11:40 2010 +0000 @@ -9948,23 +9948,18 @@ (gnus-set-mode-line 'summary))) (defun gnus-summary-push-marks-to-backend (article) - (let ((add nil) - (delete nil) + (let ((set nil) (marks gnus-article-mark-lists)) - (if (memq article gnus-newsgroup-unreads) - (push 'read add) - (push 'read delete)) + (when (memq article gnus-newsgroup-unreads) + (push 'read set)) (while marks - (when (eq (gnus-article-mark-to-type (cdar marks)) 'list) - (if (memq article (symbol-value - (intern (format "gnus-newsgroup-%s" - (caar marks))))) - (push (cdar marks) add) - (push (cdar marks) delete))) + (when (and (eq (gnus-article-mark-to-type (cdar marks)) 'list) + (memq article (symbol-value + (intern (format "gnus-newsgroup-%s" + (caar marks)))))) + (push (cdar marks) set)) (pop marks)) - (gnus-request-set-mark gnus-newsgroup-name - `(((,article) add ,add) - ((,article) del ,delete))))) + (gnus-request-set-mark gnus-newsgroup-name `(((,article) set ,set))))) (defun gnus-summary-copy-article (&optional n to-newsgroup select-method) "Copy the current article to some other group.