On Wed, Oct 13 2010, Andrew Cohen wrote: > OK here is a first pass at modifying gnus-summary-refer-thread to work > with imap. It seemed like a good idea to factor out a thread-searching > function for nnimap, so I did. Looks good. The only problem I see is that when I press A T, I then get *only* the thread I'm reading. It kicks all the other messages out of the *Summary* buffer. :-( > @@ -8828,28 +8829,35 @@ If LIMIT (the numerical prefix), fetch that many old headers instead > of what's specified by the `gnus-refer-thread-limit' variable." > (interactive "P") > (let ((id (mail-header-id (gnus-summary-article-header))) > + (refs (split-string (or > + (mail-header-references (gnus-summary-article-header)) ""))) > (limit (if limit (prefix-numeric-value limit) > gnus-refer-thread-limit))) > - (unless (eq gnus-fetch-old-headers 'invisible) > - (gnus-message 5 "Fetching headers for %s..." gnus-newsgroup-name) > - ;; Retrieve the headers and read them in. > - (if (eq (if (numberp limit) > - (gnus-retrieve-headers > - (list (min > - (+ (mail-header-number > - (gnus-summary-article-header)) > - limit) > - gnus-newsgroup-end)) > - gnus-newsgroup-name (* limit 2)) > - ;; gnus-refer-thread-limit is t, i.e. fetch _all_ > - ;; headers. > - (gnus-retrieve-headers (list gnus-newsgroup-end) > - gnus-newsgroup-name limit)) > - 'nov) > - (gnus-build-all-threads) > - (error "Can't fetch thread from back ends that don't support NOV")) > - (gnus-message 5 "Fetching headers for %s...done" gnus-newsgroup-name)) > - (gnus-summary-limit-include-thread id))) > + (if (string= (car (gnus-group-method gnus-newsgroup-name)) > "nnimap") I'm not sure such a backend check is welcome here. Isn't there a more generic way to handle that? -- Julien Danjou // ᐰ http://julien.danjou.info