Commit 4c7468f6 authored by Lars Magne Ingebrigtsen's avatar Lars Magne Ingebrigtsen Committed by Katsumi Yamaoka
Browse files

gnus-sum.el (gnus-articles-to-read): Revert back to old behaviour if we're...

gnus-sum.el (gnus-articles-to-read): Revert back to old behaviour if we're selecting a group with unread articles.
parent 448e0f79
2011-03-15 Lars Magne Ingebrigtsen <larsi@gnus.org> 2011-03-15 Lars Magne Ingebrigtsen <larsi@gnus.org>
   
* gnus-sum.el (gnus-articles-to-read): Revert back to old behaviour if
we're selecting a group with unread articles.
* nnimap.el (nnimap-open-connection-1): Allow `network-only', too. * nnimap.el (nnimap-open-connection-1): Allow `network-only', too.
   
* gssapi.el: New file separated out from imap.el to provide a general * gssapi.el: New file separated out from imap.el to provide a general
......
...@@ -5798,7 +5798,8 @@ If SELECT-ARTICLES, only select those articles from GROUP." ...@@ -5798,7 +5798,8 @@ If SELECT-ARTICLES, only select those articles from GROUP."
(defun gnus-articles-to-read (group &optional read-all) (defun gnus-articles-to-read (group &optional read-all)
"Find out what articles the user wants to read." "Find out what articles the user wants to read."
(let* ((articles (let* ((only-read-p t)
(articles
;; Select all articles if `read-all' is non-nil, or if there ;; Select all articles if `read-all' is non-nil, or if there
;; are no unread articles. ;; are no unread articles.
(if (or read-all (if (or read-all
...@@ -5822,6 +5823,7 @@ If SELECT-ARTICLES, only select those articles from GROUP." ...@@ -5822,6 +5823,7 @@ If SELECT-ARTICLES, only select those articles from GROUP."
(gnus-uncompress-range (gnus-active group))) (gnus-uncompress-range (gnus-active group)))
(gnus-cache-articles-in-group group)) (gnus-cache-articles-in-group group))
;; Select only the "normal" subset of articles. ;; Select only the "normal" subset of articles.
(setq only-read-p nil)
(gnus-sorted-nunion (gnus-sorted-nunion
(gnus-sorted-union gnus-newsgroup-dormant gnus-newsgroup-marked) (gnus-sorted-union gnus-newsgroup-dormant gnus-newsgroup-marked)
gnus-newsgroup-unreads))) gnus-newsgroup-unreads)))
...@@ -5845,18 +5847,25 @@ If SELECT-ARTICLES, only select those articles from GROUP." ...@@ -5845,18 +5847,25 @@ If SELECT-ARTICLES, only select those articles from GROUP."
(let* ((cursor-in-echo-area nil) (let* ((cursor-in-echo-area nil)
(initial (gnus-parameter-large-newsgroup-initial (initial (gnus-parameter-large-newsgroup-initial
gnus-newsgroup-name)) gnus-newsgroup-name))
(default (if only-read-p
(or initial gnus-large-newsgroup)
number))
(input (input
(read-string (read-string
(format (if only-read-p
"How many articles from %s (available %d, default %d): " (format
(gnus-group-decoded-name "How many articles from %s (available %d, default %d): "
(gnus-group-real-name gnus-newsgroup-name)) (gnus-group-decoded-name
number (gnus-group-real-name gnus-newsgroup-name))
(or initial gnus-large-newsgroup)) number default)
(format
"How many articles from %s (%d available): "
(gnus-group-decoded-name
(gnus-group-real-name gnus-newsgroup-name))
default))
nil nil
nil nil
(number-to-string (number-to-string default))))
(or initial gnus-large-newsgroup)))))
(if (string-match "^[ \t]*$" input) number input))) (if (string-match "^[ \t]*$" input) number input)))
((and (> scored marked) (< scored number) ((and (> scored marked) (< scored number)
(> (- scored number) 20)) (> (- scored number) 20))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment