# HG changeset patch # User Katsumi Yamaoka # Date 1284012972 0 # Node ID 9262b6c460dcfe45f5286d079f43839b1daf7e9e # Parent 8d976ea08d413ec429a0f9d989c3a95f5e218ebd# Parent ed38b7a7f11ef54fdadca0e050c9bd7306a00157 gnus-start.el (gnus-get-unread-articles): Set the number of unread articles of every unchecked group to t, which means unknown since the server has never been opened. diff -r 8d976ea08d41 -r 9262b6c460dc lisp/gnus/ChangeLog --- a/lisp/gnus/ChangeLog Wed Sep 08 19:37:59 2010 -0700 +++ b/lisp/gnus/ChangeLog Thu Sep 09 06:16:12 2010 +0000 @@ -1,3 +1,9 @@ +2010-09-09 Katsumi Yamaoka + + * gnus-start.el (gnus-get-unread-articles): Set the number of unread + articles of every unchecked group to t, which means unknown since the + server has never been opened. + 2010-09-08 Lars Magne Ingebrigtsen * gnus-html.el (gnus-html-show-alt-text): New command. diff -r 8d976ea08d41 -r 9262b6c460dc lisp/gnus/gnus-start.el --- a/lisp/gnus/gnus-start.el Wed Sep 08 19:37:59 2010 -0700 +++ b/lisp/gnus/gnus-start.el Thu Sep 09 06:16:12 2010 +0000 @@ -1692,7 +1692,7 @@ (gnus-agent-article-local-times 0) (archive-method (gnus-server-to-method "archive")) infos info group active method cmethod - method-type method-group-list) + method-type method-group-list entry) (gnus-message 6 "Checking new news...") (while newsrc @@ -1737,12 +1737,18 @@ (push (setq method-group-list (list method method-type nil)) type-cache)) ;; Only add groups that need updating. - (when (<= (gnus-info-level info) - (if (eq (cadr method-group-list) 'foreign) - foreign-level - alevel)) - (setcar (nthcdr 2 method-group-list) - (cons info (nth 2 method-group-list))))) + (if (<= (gnus-info-level info) + (if (eq (cadr method-group-list) 'foreign) + foreign-level + alevel)) + (setcar (nthcdr 2 method-group-list) + (cons info (nth 2 method-group-list))) + ;; The group is inactive, so we nix out the number of unread articles. + ;; It leads `(gnus-group-unread group)' to return t. See also + ;; `gnus-group-prepare-flat'. + (unless active + (when (setq entry (gnus-group-entry group)) + (setcar entry t))))) ;; Sort the methods based so that the primary and secondary ;; methods come first. This is done for legacy reasons to try to