2010-09-27 Lars Magne Ingebrigtsen <larsi@gnus.org>
+ * gnus-sum.el (gnus-summary-show-complete-article): Bind the server
+ variable instead of the Gnus variable.
+
+ * nnimap.el (nnimap-find-wanted-parts-1): Use it.
+
+ * gnus-art.el (gnus-fetch-partial-articles): Moved back to nnimap
+ again.
+
* nnimap.el (nnimap-request-accept-article): Remove the "." at the end,
since some servers don't like it.
(nnimap-open-connection): Forget credentials if the server says the
(regexp :value ".*"))
:group 'gnus-article-signature)
-(defcustom gnus-fetch-partial-articles nil
- "If non-nil, Gnus will fetch partial articles.
-If t, nnimap will fetch only the first part. If a string, it
-will fetch all parts that have types that match that string. A
-likely value would be \"text/\" to automatically fetch all
-textual parts.
-
-Currently only the nnimap backend actually supports partial
-article fetching. If the backend doesn't support it, it has no
-effect."
- :version "24.1"
- :type '(choice (const nil)
- (const t)
- (regexp))
- :group 'gnus-article)
-
(defcustom gnus-hidden-properties '(invisible t intangible t)
"Property list to use for hiding text."
:type 'sexp
(let ((gnus-keep-backlog nil)
(gnus-use-cache nil)
(gnus-agent nil)
- (gnus-fetch-partial-articles nil))
- (gnus-flush-original-article-buffer)
- (gnus-summary-show-article)))
+ (variable (format "%s-fetch-partial-articles"
+ (car (gnus-find-method-for-group
+ gnus-newsgroup-name))))
+ old-val)
+ (unwind-protect
+ (progn
+ (setq old-val (symbol-value variable))
+ (set variable nil)
+ (gnus-flush-original-article-buffer)
+ (gnus-summary-show-article))
+ (set variable old-val))))
(defun gnus-summary-show-article (&optional arg)
"Force redisplaying of the current article.
(defvoo nnimap-current-infos nil)
+(defvoo nnimap-fetch-partial-articles nil
+ "If non-nil, Gnus will fetch partial articles.
+If t, nnimap will fetch only the first part. If a string, it
+will fetch all parts that have types that match that string. A
+likely value would be \"text/\" to automatically fetch all
+textual parts.")
+
(defvar nnimap-process nil)
(defvar nnimap-status-string "")
(erase-buffer)
(with-current-buffer (nnimap-buffer)
(erase-buffer)
- (when gnus-fetch-partial-articles
- (if (eq gnus-fetch-partial-articles t)
+ (when nnimap-fetch-partial-articles
+ (if (eq nnimap-fetch-partial-articles t)
(setq parts '(1))
(nnimap-command "UID FETCH %d (BODYSTRUCTURE)" article)
(goto-char (point-min))
(number-to-string num)
(format "%s.%s" prefix num))))
(setcar (nthcdr 9 sub) id)
- (when (string-match gnus-fetch-partial-articles type)
+ (when (string-match nnimap-fetch-partial-articles type)
(push id parts))))
(incf num)))
(nreverse parts)))